/* Global Styles */
@import url('https://fonts.googleapis.com/css2?family=Noto+Sans+JP:wght@400;500;700&family=Outfit:wght@300;400;600&display=swap');

:root {
    --bg-color: #ebf0f5;
    /* Slightly darker cool gray for better contrast */
    --text-color: #1a202c;
    /* Dark Slate for text */
    --primary-color: #3b82f6;
    /* Keep Blue or use #0056b3 for darker corporate blue */
    --accent-color: #004494;
    /* Deep Blue for accent instead of Gold */
    --glass-bg: rgba(255, 255, 255, 0.9);
    --glass-border: rgba(0, 0, 0, 0.1);
    --transition-speed: 0.3s;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    color: inherit;
}

body {
    font-family: 'Outfit', 'Noto Sans JP', sans-serif;
    background-color: var(--bg-color);
    color: var(--text-color);
    line-height: 1.6;
    overflow-x: hidden;
}

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

ul {
    list-style: none;
}

img {
    max-width: 100%;
    display: block;
}

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

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

@keyframes glow {
    0% {
        box-shadow: 0 0 5px rgba(59, 130, 246, 0.2);
    }

    50% {
        box-shadow: 0 0 20px rgba(59, 130, 246, 0.5);
    }

    100% {
        box-shadow: 0 0 5px rgba(59, 130, 246, 0.2);
    }
}

.fade-in {
    opacity: 0;
    animation: fadeIn 1s ease-out forwards;
}

.delay-1 {
    animation-delay: 0.2s;
}

.delay-2 {
    animation-delay: 0.4s;
}

.delay-3 {
    animation-delay: 0.6s;
}

/* Header */
header {
    position: fixed;
    top: 0;
    width: 100%;
    z-index: 1000;
    padding: 20px 50px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(10px);
    border-bottom: 1px solid var(--glass-border);
    color: var(--text-color);
}

.logo {
    display: flex;
    flex-direction: column;
    font-size: 1.5rem;
    font-weight: 700;
    letter-spacing: 1px;
    line-height: 1;
    background: linear-gradient(90deg, #004494, var(--primary-color));
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
}

.logo-jp {
    font-size: 0.6em;
    font-weight: 500;
    margin-top: 2px;
}

nav ul {
    display: flex;
    gap: 30px;
}

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

/* Hero Section */
.hero {
    height: 100vh;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    text-align: center;
    position: relative;
    overflow: hidden;
    padding: 0 20px;
    color: #ffffff;
    /* Force white text for hero section */
}

.hero-bg {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: -1;
}

.hero-bg img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    opacity: 1;
}

.hero-bg::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.5);
    /* Dark overlay for better text readability */
}

.hero h1 {
    font-size: 4rem;
    font-weight: 700;
    margin-bottom: 20px;
    line-height: 1.1;
}

.hero p {
    font-size: 1.25rem;
    max-width: 600px;
    margin-bottom: 40px;
    color: #e6edf3;
}

.scroll-indicator {
    position: absolute;
    bottom: 30px;
    animation: bounce 2s infinite;
}

@keyframes bounce {

    0%,
    20%,
    50%,
    80%,
    100% {
        transform: translateY(0);
    }

    40% {
        transform: translateY(-10px);
    }

    60% {
        transform: translateY(-5px);
    }
}

/* Locations Section */
.locations {
    padding: 100px 50px;
    background: var(--bg-color);
}

.section-title {
    font-size: 2.5rem;
    text-align: center;
    margin-bottom: 60px;
    position: relative;
    display: block;
}

.section-title::after {
    content: '';
    display: block;
    width: 60px;
    height: 4px;
    background: var(--accent-color);
    margin: 10px auto 0;
    border-radius: 2px;
}

.location-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 30px;
    max-width: 1000px;
    margin: 0 auto;
    text-align: center;
}

.location-item {
    position: relative;
    padding: 35px 30px;
    background: linear-gradient(135deg, #ffffff 0%, #f8fafc 100%);
    border: 1px solid #e2e8f0;
    border-top: 4px solid var(--primary-color);
    border-radius: 12px;
    transition: all 0.4s ease;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.05);
    overflow: hidden;
    text-align: left;
    height: 100%;
}

.location-item:hover {
    transform: translateY(-8px);
    box-shadow: 0 20px 40px rgba(59, 130, 246, 0.1);
}

.location-bg-code {
    position: absolute;
    top: 20px;
    right: 20px;
    font-size: 4rem;
    font-weight: 900;
    color: #f1f5f9;
    z-index: 1;
    line-height: 1;
    opacity: 0.8;
    transition: all 0.4s ease;
}

.location-item:hover .location-bg-code {
    transform: scale(1.1) rotate(-5deg);
    color: #eff6ff;
}

.location-content {
    position: relative;
    z-index: 2;
}

.location-name {
    font-size: 0.9rem;
    font-weight: 700;
    color: var(--primary-color);
    letter-spacing: 2px;
    margin-bottom: 5px;
    text-transform: uppercase;
}

.location-jp {
    font-size: 1.1rem;
    color: var(--text-color);
    font-weight: 700;
    letter-spacing: 0.05em;
    margin-bottom: 20px;
    white-space: nowrap;
    /* Prevent Japanese text from breaking mid-word */
}

.location-company {
    font-size: 1rem;
    font-weight: 500;
    color: #475569;
    background: rgba(255, 255, 255, 0.8);
    backdrop-filter: blur(4px);
    padding: 10px 0 0 0;
    border-top: 1px solid #e2e8f0;
    display: block;
    width: 100%;
    line-height: 1.4;
    letter-spacing: -0.03em;
    /* Tighten spacing to prevent wrapping on long names */
}

/* Services Section */
.services {
    padding: 100px 50px;
    background: var(--bg-color);
    /* Match main background to let white cards pop */
}

.services-container {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 30px;
    max-width: 1200px;
    margin: 0 auto;
}

.service-card {
    background: #ffffff;
    border: 1px solid #e2e8f0;
    /* Subtle border for definition */
    border-radius: 20px;
    overflow: hidden;
    position: relative;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.05);
    transition: all 0.3s ease;
    display: flex;
    flex-direction: column;
}

.service-card:hover {
    box-shadow: 0 15px 30px rgba(0, 0, 0, 0.1);
    border-color: var(--primary-color);
}

.service-image {
    height: 200px;
    width: 100%;
    background: #1c2128;
    display: flex;
    justify-content: center;
    align-items: center;
    overflow: hidden;
}

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

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

.service-content {
    padding: 30px;
    flex-grow: 1;
    display: flex;
    flex-direction: column;
}

.service-title {
    font-size: 1.5rem;
    margin-bottom: 10px;
    color: var(--text-color);
}

.service-desc {
    color: #8b949e;
    margin-bottom: 20px;
    flex-grow: 1;
}

.service-link {
    display: inline-block;
    padding: 10px 20px;
    background: transparent;
    border: 1px solid var(--primary-color);
    color: var(--primary-color);
    border-radius: 50px;
    text-transform: uppercase;
    font-size: 0.8rem;
    font-weight: 600;
    transition: all 0.3s;
    align-self: flex-start;
}

.service-link:hover {
    background: var(--primary-color);
    color: #fff;
}

/* Company Section */
.company {
    padding: 100px 50px;
    background: var(--bg-color);
}

.company-box {
    max-width: 800px;
    margin: 0 auto;
    background: #ffffff;
    padding: 50px;
    border-radius: 20px;
    border: 1px solid #e2e8f0;
    /* Subtle border for definition */
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.05);
    text-align: center;
}

.company-info h3 {
    margin-bottom: 20px;
    font-size: 1.5rem;
}

.company-details p {
    margin-bottom: 10px;
    font-size: 1.1rem;
    color: #8b949e;
}

/* Contact Section */
.contact {
    padding: 100px 50px;
    background: var(--bg-color);
}

.contact-box {
    max-width: 600px;
    margin: 0 auto;
    background: #ffffff;
    padding: 40px;
    border-radius: 20px;
    border: 1px solid #e2e8f0;
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.05);
}

.form-group {
    margin-bottom: 20px;
    text-align: left;
}

.form-group label {
    display: block;
    margin-bottom: 8px;
    font-weight: 600;
    color: var(--text-color);
}

.form-group input,
.form-group textarea {
    width: 100%;
    padding: 12px 15px;
    border: 1px solid #cbd5e1;
    border-radius: 8px;
    font-family: inherit;
    font-size: 1rem;
    background: #f8fafc;
    transition: all 0.3s;
}

.form-group input:focus,
.form-group textarea:focus {
    outline: none;
    border-color: var(--primary-color);
    background: #fff;
    box-shadow: 0 0 0 3px rgba(59, 130, 246, 0.1);
}

.submit-btn {
    width: 100%;
    padding: 15px;
    background: var(--primary-color);
    color: white;
    border: none;
    border-radius: 8px;
    font-size: 1.1rem;
    font-weight: 600;
    cursor: pointer;
    transition: background 0.3s;
}

.submit-btn:hover {
    background: #2563eb;
}

.submit-btn:disabled {
    background: #94a3b8;
    cursor: not-allowed;
}

.form-status {
    margin-top: 20px;
    text-align: center;
    font-weight: 600;
}

.form-status.success {
    color: #10b981;
}

.form-status.error {
    color: #ef4444;
}

/* Footer */
footer {
    padding: 50px;
    text-align: center;
    color: #8b949e;
    border-top: 1px solid var(--glass-border);
}

/* Responsive */
@media (max-width: 768px) {
    .hero h1 {
        font-size: 2.5rem;
    }

    .hero p {
        font-size: 1rem;
    }

    header {
        padding: 15px 20px;
        flex-direction: column;
        gap: 15px;
        /* Ensure background covers the expanded height */
        height: auto;
    }

    nav ul {
        gap: 20px;
        font-size: 0.9rem;
        flex-wrap: wrap;
        justify-content: center;
    }

    .location-grid {
        grid-template-columns: 1fr;
    }

    .section-title {
        font-size: 2rem;
    }
}

/* Hide reCAPTCHA badge */
.grecaptcha-badge {
    visibility: hidden;
}

/* reCAPTCHA Legal Text */
.recaptcha-legal {
    font-size: 0.7rem;
    color: #9ca3af;
    margin-top: 15px;
    text-align: center;
    line-height: 1.4;
    opacity: 0.7;
}

.recaptcha-legal a {
    color: inherit;
    text-decoration: none;
    border-bottom: 1px dotted #9ca3af;
}

.recaptcha-legal a:hover {
    text-decoration: underline;
}