@import url('https://fonts.googleapis.com/css2?family=Inter:wght@400;600;700&family=Noto+Sans+JP:wght@400;500;700&display=swap');
@import './reset.css';

:root {
    /* Colors - Refined for "Precision" feel */
    --color-primary: #0f172a;
    /* Darker, slate-like navy */
    --color-primary-light: #1e293b;
    --color-secondary: #64748b;
    /* Slate grey */
    --color-accent: #d97706;
    /* More sophisticated amber/gold */
    --color-accent-hover: #b45309;
    --color-text: #334155;
    --color-text-light: #64748b;
    --color-bg: #f8fafc;
    /* Cool greyish white */
    --color-white: #ffffff;
    --color-border: #e2e8f0;

    /* Spacing */
    --spacing-xs: 0.5rem;
    --spacing-sm: 1rem;
    --spacing-md: 2rem;
    --spacing-lg: 5rem;
    /* More breathing room */
    --spacing-xl: 10rem;

    /* Shadows - subtly reduced for flatter, modern look */
    --shadow-sm: 0 1px 3px rgba(0, 0, 0, 0.05);
    --shadow-md: 0 4px 6px -1px rgba(0, 0, 0, 0.05);
    --shadow-lg: 0 20px 25px -5px rgba(0, 0, 0, 0.05);

    /* Border Radius - Sharper for "Industrial" feel */
    --radius-sm: 2px;
    --radius-md: 4px;
    --radius-lg: 8px;
    --radius-full: 9999px;

    /* Transitions */
    --transition-fast: 0.2s ease;
    --transition-normal: 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

body {
    font-family: 'Noto Sans JP', 'Inter', sans-serif;
    color: var(--color-text);
    background-color: var(--color-bg);
    overflow-x: hidden;
    line-height: 1.8;
    /* Improve readability */
}

h1,
h2,
h3,
h4,
h5,
h6 {
    font-weight: 700;
    line-height: 1.4;
    color: var(--color-primary);
    letter-spacing: 0.05em;
    /* Professional tracking */
    font-feature-settings: "palt";
}

a {
    text-decoration: none;
    color: inherit;
    transition: var(--transition-fast);
}

.container {
    width: 100%;
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 var(--spacing-sm);
}

/* Utilities */
.text-accent {
    color: var(--color-accent);
}

.text-primary {
    color: var(--color-primary);
}

.text-white {
    color: var(--color-white);
}

.text-center {
    text-align: center;
}

.mb-sm {
    margin-bottom: var(--spacing-sm);
}

.mb-md {
    margin-bottom: var(--spacing-md);
}

.mb-lg {
    margin-bottom: var(--spacing-lg);
}

/* Buttons - Sharper, "Engineered" look */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 1rem 2.5rem;
    font-weight: 600;
    border-radius: var(--radius-sm);
    /* Sharp corners */
    transition: all var(--transition-normal);
    cursor: pointer;
    border: none;
    font-size: 0.95rem;
    letter-spacing: 0.05em;
    position: relative;
    overflow: hidden;
}

.btn-primary {
    background-color: var(--color-primary);
    color: var(--color-white);
    border: 1px solid var(--color-primary);
}

.btn-primary:hover {
    background-color: var(--color-accent);
    border-color: var(--color-accent);
    color: var(--color-white);
    transform: translateY(-2px);
}

.btn-secondary {
    background-color: transparent;
    border: 1px solid var(--color-white);
    color: var(--color-white);
}

.btn-secondary:hover {
    background-color: var(--color-white);
    color: var(--color-primary);
}

.btn-outline {
    background-color: transparent;
    border: 1px solid var(--color-primary);
    color: var(--color-primary);
}

.btn-outline:hover {
    background-color: var(--color-primary);
    color: var(--color-white);
}

/* Header */
.header {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    z-index: 1000;
    background: rgba(255, 255, 255, 0.9);
    backdrop-filter: blur(10px);
    border-bottom: 1px solid rgba(0, 0, 0, 0.05);
    transition: all var(--transition-normal);
}

.header-inner {
    display: flex;
    justify-content: space-between;
    align-items: center;
    height: 80px;
}

.logo {
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--color-primary);
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.logo span {
    font-size: 0.9rem;
    color: var(--color-text-light);
    font-weight: 400;
}

.nav-menu {
    display: flex;
    gap: 2rem;
    align-items: center;
}

.nav-link {
    font-weight: 500;
    font-size: 0.9rem;
    color: var(--color-text);
    position: relative;
    padding: 0.5rem 0;
}

.nav-link::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 0;
    height: 1px;
    background-color: var(--color-accent);
    transition: width var(--transition-normal);
}

.nav-link:hover::after {
    width: 100%;
}

.nav-link:hover {
    color: var(--color-primary);
}

.header-cta {
    display: flex;
    align-items: center;
    gap: 1rem;
}

.header-tel {
    font-weight: 700;
    color: var(--color-primary);
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

/* Hero Section - Deep Technical Blue */
.hero {
    position: relative;
    height: 90vh;
    /* Slightly adjusted */
    min-height: 600px;
    display: flex;
    align-items: center;
    background: #0f172a;
    /* Fallback */
    background: radial-gradient(circle at 70% 30%, #1e293b 0%, #0f172a 100%);
    color: var(--color-white);
    overflow: hidden;
}

.hero::before {
    /* Technical Grid */
    content: '';
    position: absolute;
    inset: 0;
    background-image:
        linear-gradient(rgba(255, 255, 255, 0.03) 1px, transparent 1px),
        linear-gradient(90deg, rgba(255, 255, 255, 0.03) 1px, transparent 1px);
    background-size: 60px 60px;
    pointer-events: none;
}

.hero-content {
    position: relative;
    z-index: 10;
    max-width: 800px;
    padding-top: 4rem;
}

.hero-title {
    font-size: 3.5rem;
    line-height: 1.2;
    margin-bottom: 2rem;
    color: var(--color-white);
    letter-spacing: 0.05em;
    opacity: 0;
    animation: fadeUp 1s cubic-bezier(0.2, 0.8, 0.2, 1) forwards 0.2s;
}

.hero-sub {
    font-size: 1.1rem;
    margin-bottom: 3rem;
    opacity: 0.9;
    font-weight: 400;
    border-left: 2px solid var(--color-accent);
    /* Thinner accent line */
    padding-left: 1.5rem;
    line-height: 1.8;
    opacity: 0;
    animation: fadeUp 1s cubic-bezier(0.2, 0.8, 0.2, 1) forwards 0.4s;
}

.hero-actions {
    display: flex;
    gap: 1rem;
    opacity: 0;
    animation: fadeUp 1s cubic-bezier(0.2, 0.8, 0.2, 1) forwards 0.6s;
}

/* Sections Common */
.section {
    padding: var(--spacing-xl) 0;
}

.section-grey {
    background-color: #F0F4EF;
}

/* Section Title - Modern Style */
.section-title {
    font-size: 2rem;
    text-align: center;
    margin-bottom: 4rem;
    color: var(--color-primary);
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 1rem;
}

.section-title::before,
.section-title::after {
    content: '';
    display: block;
    width: 40px;
    height: 1px;
    background-color: var(--color-accent);
    flex-shrink: 0;
}

@media (max-width: 768px) {
    .section-title {
        font-size: 1.5rem;
        gap: 0.5rem;
        word-break: keep-all;
        /* Prevent awkward breaks */
    }

    .section-title::before,
    .section-title::after {
        width: 15px;
        /* Smaller lines on mobile */
    }
}

/* Cards (Services) - "Precision Board" Style */
.card-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
    gap: 2rem;
}

.card {
    background: var(--color-white);
    border: 1px solid var(--color-border);
    border-radius: var(--radius-sm);
    padding: 3rem 2.5rem;
    transition: all var(--transition-normal);
    position: relative;
    box-shadow: none;
    /* Reset old shadow */
}

.card:hover {
    border-color: var(--color-accent);
    transform: translateY(-4px);
    box-shadow: var(--shadow-lg);
}

.card::before {
    /* Top Accent Line on Hover */
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 0%;
    height: 3px;
    background: var(--color-accent);
    transition: width var(--transition-normal);
}

.card:hover::before {
    width: 100%;
    opacity: 1;
    /* Ensure visible */
}

.card-icon {
    font-size: 2.5rem;
    color: var(--color-accent);
    margin-bottom: 1.5rem;
}

.card-title {
    font-size: 1.25rem;
    margin-bottom: 1rem;
    border-bottom: 1px solid var(--color-border);
    padding-bottom: 1rem;
}

.card-text {
    color: var(--color-text-light);
    margin-bottom: 1.5rem;
    font-size: 0.95rem;
}

.tag-list {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
}

.tag {
    background: transparent;
    color: var(--color-secondary);
    border: 1px solid var(--color-border);
    padding: 0.25rem 0.75rem;
    border-radius: var(--radius-full);
    font-size: 0.75rem;
    font-weight: 500;
}

/* Strength Section (3 Columns) */
.strength-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 2rem;
}

.strength-item {
    text-align: center;
}

.strength-num {
    font-size: 4rem;
    font-weight: 700;
    color: rgba(11, 37, 69, 0.1);
    line-height: 1;
    margin-bottom: -1.5rem;
    position: relative;
    z-index: 0;
}

.strength-title {
    font-size: 1.5rem;
    position: relative;
    z-index: 1;
    margin-bottom: 1rem;
}

/* Guide Section */
.guide-box {
    background: var(--color-white);
    border-radius: var(--radius-lg);
    padding: 3rem;
    box-shadow: var(--shadow-lg);
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 3rem;
    align-items: center;
}

.guide-step {
    display: flex;
    align-items: flex-start;
    margin-bottom: 1.5rem;
}

.step-num {
    background: var(--color-primary);
    color: var(--color-white);
    width: 30px;
    height: 30px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 700;
    margin-right: 1rem;
    flex-shrink: 0;
}

/* Works Gallery */
.gallery-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 1.5rem;
}

.gallery-item {
    border-radius: var(--radius-md);
    overflow: hidden;
    position: relative;
    height: 250px;
    cursor: pointer;
}

.gallery-img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.5s ease;
}

.gallery-overlay {
    position: absolute;
    inset: 0;
    background: rgba(11, 37, 69, 0.8);
    opacity: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: opacity 0.3s ease;
}

.gallery-text {
    color: var(--color-white);
    font-weight: 700;
    transform: translateY(20px);
    transition: transform 0.3s ease;
}

.gallery-item:hover .gallery-img {
    transform: scale(1.1);
}

.gallery-item:hover .gallery-overlay {
    opacity: 1;
}

.gallery-item:hover .gallery-text {
    transform: translateY(0);
}

/* CTA Section */
.cta-section {
    background: var(--color-primary);
    color: var(--color-white);
    text-align: center;
    padding: 5rem 1rem;
}

.cta-title {
    color: var(--color-white);
    font-size: 2.5rem;
    margin-bottom: 1rem;
}

/* Footer */
.footer {
    background: #051628;
    color: #8da9c4;
    padding: 3rem 0;
    font-size: 0.9rem;
}

.footer .logo {
    color: var(--color-white);
    margin-bottom: 0.5rem;
}

.footer-content {
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    gap: 1.5rem;
}

/* Animations */
@keyframes fadeUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Mobile */
.mobile-toggle {
    display: none;
    font-size: 1.5rem;
    background: none;
    border: none;
    color: var(--color-primary);
}

@media (max-width: 1024px) {
    .header-inner {
        height: 60px;
    }

    .logo {
        font-size: 1.2rem;
    }

    .mobile-toggle {
        display: block;
    }

    .nav-menu {
        position: fixed;
        top: 60px;
        left: 0;
        width: 100%;
        background: var(--color-white);
        flex-direction: column;
        padding: 2rem;
        box-shadow: var(--shadow-md);
        transform: translateY(-150%);
        transition: transform var(--transition-normal);
    }

    .nav-menu.active {
        transform: translateY(0);
    }

    .header-cta {
        display: none;
    }

    .hero-title {
        font-size: 2.5rem;
    }

    .strength-grid,
    .guide-box {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 1280px) {
    .nav-menu {
        gap: 1rem;
    }

    .logo {
        font-size: 1.3rem;
    }

    .header-cta .btn {
        padding: 0.5rem 1rem;
    }
}