/* Base Styles */
body, p {
    font-family: "Noto Sans JP", sans-serif;
    line-height: 1.8;
    letter-spacing: 0.05em;
    color: #333;
    overflow-x: hidden;
    font-size: 16px !important; /* PC */
}

/* Hide all scrollbars globally */
*::-webkit-scrollbar {
    display: none !important;
}
* {
    -ms-overflow-style: none !important;
    scrollbar-width: none !important;
}

@media (max-width: 767px) {
    body, p {
        font-size: 14px !important; /* SP */
    }
}



/* Section Spacing - Unified */
section, .section-wrapper {
    padding-top: 70px;
    padding-bottom: 70px;
    margin-bottom: 0 !important;
}

/* SP Horizontal Padding */
@media (max-width: 767px) {
    .container, .px-4 {
        padding-left: 10px !important;
        padding-right: 10px !important;
    }
    .p-10 {
        padding: 40px 10px !important;
    }
}

/* Section Header: Text-Only Stylish Design */
.section-header {
    text-align: center;
    margin-bottom: 60px;
    display: flex;
    flex-direction: column;
    align-items: center;
}

.section-header .title {
    font-size: 2rem;
    font-weight: 700;
    color: #0f172a; /* primary color */
    letter-spacing: 0.15em;
    position: relative;
    padding-bottom: 15px;
    display: inline-block;
}

.section-header .title::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 50%;
    transform: translateX(-50%);
    width: 40px;
    height: 2px;
    background-color: #c5a059; /* accent color */
}

.section-header .subtitle {
    font-size: 0.75rem;
    color: #c5a059;
    font-weight: 700;
    letter-spacing: 0.3em;
    text-transform: uppercase;
    margin-bottom: 5px;
}


/* FV Swiper Height */
.swiper-fv {
    width: 100%;
    height: 100vh;
}
.swiper-fv img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    vertical-align: bottom;
}

/* Parallax Effect */
.parallax-bg {
    background-attachment: fixed;
    background-position: center;
    background-repeat: no-repeat;
    background-size: cover;
}
@media (max-width: 767px) {
    .parallax-bg {
        background-attachment: scroll; /* Mobile parallax fix */
    }
}

/* Scroll Animation Indicator */
@keyframes bounce-custom {
    0%, 100% { transform: translateY(-100%); }
    50% { transform: translateY(100%); }
}
.animate-bounce-custom {
    animation: bounce-custom 2s ease-in-out infinite;
}

/* Broken Grid Decoration */
.broken-grid-img {
    position: relative;
    z-index: 1;
}
.broken-grid-img::after {
    content: '';
    position: absolute;
    top: 20px;
    right: -20px;
    width: 100%;
    height: 100%;
    border: 2px solid #c5a059;
    z-index: -1;
}
@media (max-width: 767px) {
    .broken-grid-img::after {
        right: 0;
        bottom: -20px;
        top: auto;
        width: 100%;
        height: 100%;
    }
}

/* Mobile Menu Overlay */
.mobile-menu-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(15, 23, 42, 0.98);
    z-index: 100;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    opacity: 0;
    visibility: hidden;
    transition: all 0.4s cubic-bezier(0.23, 1, 0.32, 1);
}
.mobile-menu-overlay.active {
    opacity: 1;
    visibility: visible;
}

/* SP Follow CTA */
@media (max-width: 767px) {
    .sp-cta-bar {
        display: flex;
        position: fixed;
        bottom: 0;
        left: 0;
        width: 100%;
        height: 70px;
        background: #0f172a;
        z-index: 90;
        box-shadow: 0 -5px 15px rgba(0,0,0,0.3);
    }
}

/* Gallery Marquee Style */
.gallery-marquee-container {
    overflow: hidden;
    width: 100%;
    padding: 40px 0;
}
.gallery-marquee-inner {
    display: flex;
    width: calc(400px * 20); /* Updated for 400px items */
    animation: marquee 50s linear infinite;
}
.gallery-marquee-item {
    width: 400px;
    height: 300px; /* Uniform height */
    flex-shrink: 0;
    padding: 0 15px;
}
.gallery-marquee-item img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    border-radius: 12px;
    box-shadow: 0 10px 30px rgba(0,0,0,0.1);
}
@keyframes marquee {
    0% { transform: translateX(0); }
    100% { transform: translateX(calc(-400px * 10)); } /* Half of total count */
}

/* GLightbox Custom Styling */
.glightbox-container .gslide-image {
    box-shadow: 0 10px 50px rgba(0,0,0,0.5);
    border-radius: 4px;
}
.glightbox-container .gclose, .glightbox-container .gnext, .glightbox-container .gprev {
    background-color: rgba(255, 255, 255, 0.1) !important;
    backdrop-filter: blur(5px);
    border-radius: 50% !important;
    width: 45px !important;
    height: 45px !important;
    display: flex !important;
    align-items: center;
    justify-content: center;
    transition: all 0.3s ease;
}
.glightbox-container .gclose:hover, .glightbox-container .gnext:hover, .glightbox-container .gprev:hover {
    background-color: #c5a059 !important;
}
.glightbox-container .gclose {
    top: 20px !important;
    right: 20px !important;
}
.glightbox-container .gclose svg {
    width: 18px !important;
    height: 18px !important;
}

/* Simple Fade Animation */
.fade-in {
    opacity: 0;
    transform: translateY(20px);
    transition: opacity 0.6s ease-out, transform 0.6s ease-out;
}
.fade-in.visible {
    opacity: 1;
    transform: translateY(0);
}

/* --- CTA Section Redesign --- */
.cta-section {
    position: relative;
    padding: 6rem 0;
    background: linear-gradient(135deg, #1e1b4b 0%, #0f172a 100%); /* Deep Indigo to Navy */
    overflow: hidden;
}

.cta-section::after {
    content: '';
    position: absolute;
    inset: 0;
    background-image: url('img/fv.jpg');
    background-size: cover;
    background-position: center;
    opacity: 0.15;
    z-index: 1;
}

.cta-card-wrap {
    position: relative;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 3rem;
    z-index: 10;
}

.cta-btn-premium {
    position: relative;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 2.5rem 4rem;
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid rgba(255, 255, 255, 0.05);
    backdrop-filter: blur(15px);
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.2);
    transition: all 0.5s cubic-bezier(0.23, 1, 0.32, 1);
    min-width: 320px;
}

.cta-btn-premium:hover {
    background: rgba(255, 255, 255, 0.08);
    border-color: #00d2ff;
    box-shadow: 0 0 30px rgba(0, 210, 255, 0.2);
    transform: translateY(-5px);
}

.cta-btn-premium.accent {
    border-color: rgba(255, 152, 0, 0.3);
}

.cta-btn-premium.accent:hover {
    border-color: #ff9800;
    box-shadow: 0 0 30px rgba(255, 152, 0, 0.2);
}

.cta-icon-wrap {
    margin-bottom: 1.5rem;
    color: #00d2ff;
    transition: transform 0.5s ease;
}

.cta-btn-premium:hover .cta-icon-wrap {
    transform: scale(1.2);
}

.cta-btn-premium.accent .cta-icon-wrap {
    color: #ff9800;
}

.cta-label {
    font-size: 0.65rem;
    font-weight: 900;
    letter-spacing: 0.4em;
    text-transform: uppercase;
    color: rgba(255, 255, 255, 0.5);
    margin-bottom: 0.5rem;
}

.cta-main-text {
    font-size: 1.5rem;
    font-weight: 900;
    color: #ffffff;
    letter-spacing: 0.1em;
}

/* Decorative HUD lines for CTA */
.cta-line {
    position: absolute;
    background: #00d2ff;
    opacity: 0.2;
}

@media (max-width: 767px) {
    .cta-btn-premium {
        width: 100%;
        min-width: auto;
        padding: 2rem;
    }
    .cta-card-wrap {
        gap: 1.5rem;
    }
}

/* --- Service Section Redesign --- */
.service-bg-text {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -100%);
    font-size: 18vw;
    font-weight: 900;
    background: linear-gradient(180deg, rgba(255,255,255,0.05) 0%, transparent 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    z-index: 0;
    white-space: nowrap;
    pointer-events: none;
    font-family: 'Noto Serif JP', serif;
    letter-spacing: 0.1em;
}

.scanline {
    width: 100%;
    height: 100px;
    z-index: 5;
    background: linear-gradient(0deg, rgba(0, 210, 255, 0) 0%, rgba(0, 210, 255, 0.05) 50%, rgba(0, 210, 255, 0) 100%);
    opacity: 0.1;
    position: absolute;
    bottom: 100%;
    animation: scanline 8s linear infinite;
}

@keyframes scanline {
    0% { transform: translateY(0); }
    100% { transform: translateY(100vh); }
}

.service-card {
    position: relative;
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid rgba(255, 255, 255, 0.05);
    backdrop-filter: blur(10px);
    border-radius: 4px;
    padding: 1.5rem;
    transition: all 0.5s cubic-bezier(0.23, 1, 0.32, 1);
    height: 100%;
    overflow: hidden;
}

.service-card:hover {
    background: rgba(255, 255, 255, 0.06);
    border-color: rgba(0, 210, 255, 0.3);
    transform: translateY(-10px);
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.3);
}

.service-card:hover::before {
    transform: translateX(100%);
}

.tech-number {
    font-size: 5rem;
    font-weight: 900;
    line-height: 1;
    color: transparent;
    -webkit-text-stroke: 1px rgba(0, 210, 255, 0.3);
    margin-bottom: 1.5rem;
    display: block;
    font-family: 'Noto Sans JP', sans-serif;
    transition: all 0.5s ease;
}

.service-card:hover .tech-number {
    -webkit-text-stroke: 1px rgba(0, 210, 255, 0.8);
    text-shadow: 0 0 20px rgba(0, 210, 255, 0.4);
}

.tech-tag {
    display: inline-block;
    font-size: 0.6rem;
    font-weight: 900;
    letter-spacing: 0.2em;
    padding: 0.25rem 0.75rem;
    border: 1px solid rgba(255, 152, 0, 0.3);
    color: #ff9800;
    margin-bottom: 1rem;
    text-transform: uppercase;
}

.service-img-container {
    position: relative;
    width: 100%;
    padding-top: 125%; /* 4:5 Aspect Ratio */
    overflow: hidden;
    border-radius: 2px;
}

.service-img-container img {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.8s cubic-bezier(0.23, 1, 0.32, 1);
}

.service-card:hover .service-img-container img {
    transform: scale(1.1);
}

.tech-corner {
    position: absolute;
    width: 20px;
    height: 20px;
    border: 1px solid #00d2ff;
    z-index: 10;
}

.corner-tl { top: 10px; left: 10px; border-right: 0; border-bottom: 0; }
.corner-tr { top: 10px; right: 10px; border-left: 0; border-bottom: 0; }
.corner-bl { bottom: 10px; left: 10px; border-right: 0; border-top: 0; }
.corner-br { bottom: 10px; right: 10px; border-left: 0; border-top: 0; }

@media (max-width: 767px) {
    .tech-number {
        font-size: 3.5rem;
    }
}

/* --- Introduction (Diagnosis) Section --- */
.intro-bg-text {
    position: absolute;
    top: 10%;
    left: 5%;
    font-size: 10vw;
    font-weight: 900;
    color: rgba(15, 23, 42, 0.03);
    z-index: 0;
    pointer-events: none;
    font-family: 'Noto Serif JP', serif;
}

.diagnosis-card {
    background: #fff;
    border-left: 4px solid #ff9800;
    padding: 1.5rem;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.05);
    transition: all 0.4s ease;
    position: relative;
    overflow: hidden;
}

.diagnosis-card:hover {
    transform: translateX(10px);
    box-shadow: 0 15px 40px rgba(0, 0, 0, 0.1);
}

.diagnosis-card p {
    overflow: hidden;
}

.diagnosis-card::after {
    content: '';
    position: absolute;
    right: -20px;
    bottom: -20px;
    width: 60px;
    height: 60px;
    background: rgba(0, 210, 255, 0.03);
    border-radius: 50%;
}

.diagnosis-num {
    font-size: 0.75rem;
    font-weight: 900;
    color: #ff9800;
    margin-bottom: 0.5rem;
    display: block;
    letter-spacing: 0.2em;
}

.intro-img-frame {
    position: relative;
    padding: 20px;
}

.intro-img-frame::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 60%;
    height: 60%;
    border-top: 2px solid #00d2ff;
    border-left: 2px solid #00d2ff;
    z-index: 10;
}

.intro-img-frame::after {
    content: '';
    position: absolute;
    bottom: 0;
    right: 0;
    width: 60%;
    height: 60%;
    border-bottom: 2px solid #ff9800;
    border-right: 2px solid #ff9800;
    z-index: 10;
}

@media (max-width: 767px) {
    .intro-bg-text {
        font-size: 20vw;
        top: 5%;
    }
}
/* --- Message Section Redesign --- */
.message-content-wrap {
    background: rgba(15, 23, 42, 0.02);
    border: 1px solid rgba(15, 23, 42, 0.05);
    padding: 2rem;
    position: relative;
    overflow: hidden;
}

.message-quote-icon {
    position: absolute;
    top: -20px;
    left: -20px;
    font-size: 10rem;
    color: rgba(0, 210, 255, 0.05);
    font-family: serif;
    line-height: 1;
    pointer-events: none;
}

.message-philosophy-label {
    display: inline-flex;
    align-items: center;
    gap: 1rem;
    font-size: 0.65rem;
    font-weight: 900;
    letter-spacing: 0.3em;
    color: #c5a059;
    text-transform: uppercase;
}

.message-philosophy-label::before {
    content: '';
    width: 30px;
    height: 1px;
    background: #c5a059;
}

.message-img-frame {
    position: relative;
    z-index: 1;
}

.message-img-frame::after {
    content: '';
    position: absolute;
    top: -30px;
    left: -30px;
    width: 100px;
    height: 100px;
    border-top: 4px solid #00d2ff;
    border-left: 4px solid #00d2ff;
    z-index: -1;
}

.message-img-frame::before {
    content: '';
    position: absolute;
    bottom: -30px;
    right: -30px;
    width: 150px;
    height: 150px;
    background: radial-gradient(circle, #ff9800 1px, transparent 1px);
    background-size: 10px 10px;
    opacity: 0.2;
    z-index: -1;
}

/* --- Staff Card Redesign --- */
.staff-card {
    background: #fff;
    border: 1px solid rgba(15, 23, 42, 0.05);
    padding: 3rem 2rem;
    position: relative;
    transition: all 0.5s cubic-bezier(0.23, 1, 0.32, 1);
    overflow: hidden;
    height: 100%;
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
}

.staff-card:hover {
    transform: translateY(-10px);
    box-shadow: 0 30px 60px rgba(15, 23, 42, 0.1);
    border-color: #00d2ff;
}

.staff-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 4px;
    background: #00d2ff;
    transform: scaleX(0);
    transition: transform 0.5s ease;
    transform-origin: left;
}

.staff-card:hover::before {
    transform: scaleX(1);
}

.staff-img-wrap {
    position: relative;
    width: 180px;
    height: 180px;
    margin-bottom: 2rem;
}

.staff-img-wrap img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    border-radius: 50%;
    border: 8px solid #f8fafc;
    transition: all 0.5s ease;
}

.staff-card:hover .staff-img-wrap img {
    border-color: #00d2ff;
}

.staff-badge {
    position: absolute;
    bottom: 5px;
    right: 5px;
    background: #0f172a;
    color: #fff;
    font-size: 0.6rem;
    font-weight: 900;
    padding: 0.5rem 1rem;
    border-radius: 20px;
    letter-spacing: 0.1em;
    box-shadow: 0 4px 10px rgba(0,0,0,0.2);
}

.staff-card.accent .staff-badge {
    background: #ff9800;
}

.staff-status {
    font-size: 0.65rem;
    font-weight: 900;
    color: #00d2ff;
    letter-spacing: 0.2em;
    margin-bottom: 1rem;
    display: block;
}

.staff-name {
    font-size: 1.75rem;
    font-weight: 900;
    color: #0f172a;
    margin-bottom: 0.5rem;
}

.staff-title {
    font-size: 0.85rem;
    font-weight: 700;
    color: #c5a059;
    letter-spacing: 0.1em;
}

.staff-bio {
    margin-top: 2rem;
    font-size: 0.9rem;
    color: #64748b;
    line-height: 1.6;
}

@media (max-width: 767px) {
    .staff-card {
        padding: 40px 10px !important;
    }
}

/* --- Utility Overrides --- */
@media (min-width: 768px) {
    .md\:text-5xl {
        font-size: 30px !important;
        line-height: 1 !important;
    }
}

/* Smartphone (SP) Overrides */
@media (max-width: 767px) {
    .py-4 {
        padding-top: 15px !important;
        padding-bottom: 15px !important;
    }
    .px-8 {
        padding-left: 15px !important;
        padding-right: 15px !important;
    }
    .message-content-wrap {
        padding: 40px 10px !important;
    }
    
    /* TV & About Section SP Typography */
    #tv .text-3xl, #about h3.text-3xl {
        font-size: 24px !important;
    }
    #tv .leading-tight, #about h3.leading-tight {
        line-height: 1.4 !important;
    }

    .py-32 {
        padding-top: 3rem !important;
        padding-bottom: 3rem !important;
    }
}

/* --- Styles moved from index.html --- */
#top-btn {
    display: flex;
    opacity: 0;
    transition: opacity 0.3s, transform 0.3s;
}

/* Fixed Header spacing fix */
body {
    padding-top: 80px;
    /* Exact height of h-20 header */
}

/* Vertical Text Style for FV - PC ONLY */
@media (min-width: 768px) {
    .vertical-text-pc {
        writing-mode: vertical-rl;
        text-orientation: mixed;
    }
}

/* Text Shadow for better contrast */
.shadow-title {
    text-shadow: 0 4px 10px rgba(0, 0, 0, 0.4);
}

/* Animated line indicator */
@keyframes scroll-line {
    0% {
        transform: translateY(-100%);
    }

    100% {
        transform: translateY(100%);
    }
}

.animate-scroll-line {
    animation: scroll-line 2s infinite ease-in-out;
}

@keyframes spin-slow {
    from {
        transform: rotate(0deg);
    }

    to {
        transform: rotate(360deg);
    }
}

.animate-spin-slow {
    animation: spin-slow 20s linear infinite;
}

.animate-spin-reverse {
    animation: spin-slow 30s linear infinite reverse;
}

@keyframes pulse-glow {

    0%,
    100% {
        opacity: 0.8;
        box-shadow: 0 0 10px #ff9800;
    }

    50% {
        opacity: 1;
        box-shadow: 0 0 25px #ff9800;
    }
}

.animate-pulse-glow {
    animation: pulse-glow 3s infinite ease-in-out;
}

.bg-grid {
    background-image: radial-gradient(circle, rgba(255, 255, 255, 0.05) 1px, transparent 1px);
    background-size: 30px 30px;
}

/* Service Section Title Color Fix */
#service .title {
    color: #ffffff !important;
}

/* Container for internal elements to stay "inside" */
.fv-content-inner {
    max-width: 1400px;
    margin: 0 auto;
    position: relative;
    height: 100%;
}

/* Ken Burns Zoom Animation for FV */
@keyframes fv-zoom {
    0% { transform: scale(1); }
    100% { transform: scale(1.1); }
}

.fv-zoom-animate {
    animation: fv-zoom 20s ease-out forwards;
}

#tv {
    overflow-x: hidden;
}

.intro-bg-text {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    font-size: 20vw;
    font-weight: 900;
    color: rgba(15, 23, 42, 0.03);
    z-index: 0;
    white-space: nowrap;
    pointer-events: none;
    font-family: 'Noto Serif JP', serif;
    letter-spacing: 0.2em;
}

/* Global Heading Line-Height Override - Placed at end for priority */
h1, h2, h3, h4, h5, h6, 
.leading-tight, .leading-snug, .leading-normal, .leading-relaxed, .leading-loose,
.text-3xl, .text-4xl, .text-5xl, .text-6xl, .md\:text-6xl {
    line-height: 1.3 !important;
}
