:root {
    --bg-color: #050505;
    --text-color: #f0f0f0;
    --text-muted: #a0a0a0;
    --accent-color: #ffffff;
    --surface-color: #111111;
    --surface-hover: #1a1a1a;
    --border-color: #222222;
    --font-primary: Inter, 'Noto Sans JP', 'Hiragino Kaku Gothic ProN', 'Yu Gothic', Meiryo, system-ui, sans-serif;
    --transition: all 0.3s cubic-bezier(0.25, 0.8, 0.25, 1);
}

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

html {
    scroll-behavior: smooth;
}

section[id] {
    scroll-margin-top: 96px;
}

body {
    background-color: var(--bg-color);
    color: var(--text-color);
    font-family: var(--font-primary);
    line-height: 1.6;
    overflow-x: hidden;
    -webkit-font-smoothing: antialiased;
}

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

a:focus-visible,
button:focus-visible {
    outline: 2px solid var(--accent-color);
    outline-offset: 4px;
}

.skip-link {
    position: fixed;
    top: 0.75rem;
    left: 0.75rem;
    z-index: 2000;
    padding: 0.75rem 1rem;
    color: var(--bg-color);
    background: var(--text-color);
    border-radius: 4px;
    transform: translateY(-160%);
}

.skip-link:focus {
    transform: translateY(0);
}

ul {
    list-style: none;
}

/* Typography */
h1, h2, h3 {
    font-weight: 800;
    line-height: 1.2;
    letter-spacing: -0.02em;
}

/* Header */
.header {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    z-index: 1000;
    padding: 1.5rem 0;
    transition: var(--transition);
    background: transparent;
}

.header.scrolled {
    background: rgba(5, 5, 5, 0.85);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    padding: 1rem 0;
    border-bottom: 1px solid var(--border-color);
}

.header-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 2rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.logo-text {
    font-size: 1.8rem;
    font-weight: 800;
    letter-spacing: -0.05em;
    font-style: italic;
    background: linear-gradient(135deg, #ffffff 0%, #888888 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    line-height: 1;
}

.nav-list {
    display: flex;
    align-items: center;
    gap: 2.5rem;
}

.nav-toggle {
    display: none;
    padding: 0.6rem 0.9rem;
    color: var(--text-color);
    background: transparent;
    border: 1px solid var(--border-color);
    border-radius: 4px;
    font: inherit;
    font-size: 0.8rem;
    font-weight: 600;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    cursor: pointer;
}

.nav-link {
    font-size: 0.9rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    color: var(--text-muted);
}

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

.btn-contact {
    border: 1px solid var(--border-color);
    padding: 0.6rem 1.2rem;
    border-radius: 4px;
    color: var(--text-color);
}

.btn-contact:hover {
    background: var(--text-color);
    color: var(--bg-color);
}

/* Hero Section */
.hero {
    position: relative;
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 0 2rem;
    text-align: center;
    overflow: hidden;
}

.hero-content {
    position: relative;
    z-index: 2;
    max-width: 900px;
}

.hero-title {
    font-size: clamp(3rem, 6vw, 5rem);
    margin-bottom: 1.5rem;
    text-wrap: balance;
}

.highlight {
    background: linear-gradient(90deg, #fff, #777);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

.hero-subtitle {
    font-size: clamp(1.1rem, 2vw, 1.25rem);
    color: var(--text-muted);
    margin-bottom: 3rem;
    font-weight: 300;
    text-wrap: balance;
}

.hero-actions {
    display: flex;
    gap: 1.5rem;
    justify-content: center;
}

.btn {
    display: inline-block;
    padding: 1rem 2.5rem;
    font-size: 1rem;
    font-weight: 600;
    border-radius: 4px;
    cursor: pointer;
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

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

.btn-primary:hover {
    background: transparent;
    color: var(--text-color);
}

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

.btn-secondary:hover {
    border-color: var(--text-color);
}

.hero-bg-effect {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 60vw;
    height: 60vw;
    background: radial-gradient(circle, rgba(255,255,255,0.03) 0%, rgba(0,0,0,0) 70%);
    z-index: 1;
    pointer-events: none;
}

/* Sections General */
.section {
    padding: 8rem 0;
}

.section-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 2rem;
}

.section-title {
    font-size: 2.5rem;
    margin-bottom: 4rem;
    position: relative;
    display: inline-block;
}

.section-title::after {
    content: '';
    position: absolute;
    bottom: -10px;
    left: 0;
    width: 40px;
    height: 2px;
    background: var(--accent-color);
}

/* About Section */
.about-grid {
    max-width: 800px;
    margin: 0 auto;
    text-align: center;
}

.about-text p {
    font-size: 1.1rem;
    color: var(--text-muted);
    margin-bottom: 1.5rem;
}

/* Services Section */
.services-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(min(100%, 300px), 1fr));
    gap: 2rem;
}

.service-card {
    background: var(--surface-color);
    border: 1px solid var(--border-color);
    padding: 3rem 2rem;
    border-radius: 8px;
    transition: var(--transition);
}

.service-card:hover {
    transform: translateY(-10px);
    border-color: #444;
    background: var(--surface-hover);
}

.service-icon {
    font-size: 1.5rem;
    font-weight: 800;
    color: var(--text-muted);
    margin-bottom: 2rem;
    font-family: monospace;
}

.service-name {
    font-size: 1.5rem;
    margin-bottom: 1rem;
}

.service-desc {
    color: var(--text-muted);
    font-size: 1rem;
}

.service-related {
    display: grid;
    grid-template-columns: 1fr auto;
    gap: 0.25rem 1rem;
    margin-top: 2rem;
    padding-top: 1.25rem;
    border-top: 1px solid var(--border-color);
}

.service-related-label {
    grid-column: 1 / -1;
    color: #777;
    font-size: 0.7rem;
    font-weight: 600;
    letter-spacing: 0.12em;
    text-transform: uppercase;
}

.service-related-name {
    color: var(--text-color);
    font-size: 0.9rem;
    font-weight: 700;
    letter-spacing: 0.04em;
}

.service-related-status {
    align-self: center;
    color: #777;
    font-size: 0.72rem;
}

/* Contact Section */
.contact-box {
    text-align: center;
    padding: 6rem 2rem;
    background: var(--surface-color);
    border: 1px solid var(--border-color);
    border-radius: 8px;
}

.contact-box .section-title::after {
    left: 50%;
    transform: translateX(-50%);
}

.contact-text {
    font-size: 1.2rem;
    color: var(--text-muted);
    margin-bottom: 3rem;
}

/* Company Section */
.company-box {
    background: var(--surface-color);
    border: 1px solid var(--border-color);
    border-radius: 8px;
    padding: 3rem 4rem;
}

.company-list {
    display: grid;
    grid-template-columns: 200px 1fr;
    gap: 1.5rem 2rem;
    align-items: start;
}

.company-list dt {
    font-weight: 600;
    color: var(--text-muted);
    border-bottom: 1px solid #222;
    padding-bottom: 0.5rem;
}

.company-list dd {
    border-bottom: 1px solid #222;
    padding-bottom: 0.5rem;
    color: var(--text-color);
}

.company-list dd:last-child,
.company-list dt:last-of-type:last-child {
    border-bottom: none;
}

.text-small {
    font-size: 0.85rem;
    color: var(--text-muted);
}

.text-link,
.contact-email {
    text-decoration: underline;
    text-underline-offset: 0.2em;
}

.contact-email {
    color: #fff;
}

/* Footer */
.footer {
    border-top: 1px solid var(--border-color);
    padding: 4rem 0 2rem;
}

.footer-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 2rem;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 2rem;
}

.footer-links {
    display: flex;
    gap: 2rem;
}

.footer-links a {
    color: var(--text-muted);
    font-size: 0.9rem;
}

.footer-links a:hover {
    color: var(--accent-color);
}

.copyright {
    color: #444;
    font-size: 0.8rem;
    margin-top: 2rem;
}

/* Legal pages */
.legal-page {
    background: var(--bg-color);
}

.legal-header {
    background: rgba(5, 5, 5, 0.94);
    border-bottom: 1px solid var(--border-color);
}

.back-link {
    color: var(--text-muted);
    font-size: 0.9rem;
    font-weight: 600;
    letter-spacing: 0.05em;
    text-transform: uppercase;
}

.back-link:hover {
    color: var(--text-color);
}

.legal-main {
    padding: 10rem 2rem 6rem;
}

.legal-article {
    max-width: 800px;
    margin: 0 auto;
}

.legal-eyebrow {
    margin-bottom: 1rem;
    color: var(--text-muted);
    font-size: 0.85rem;
    font-weight: 600;
    letter-spacing: 0.12em;
    text-transform: uppercase;
}

.legal-article h1 {
    margin-bottom: 2.5rem;
    font-size: clamp(2.2rem, 5vw, 3.5rem);
}

.legal-article section {
    margin-top: 3rem;
}

.legal-article h2 {
    margin-bottom: 1rem;
    font-size: 1.25rem;
}

.legal-article p {
    color: var(--text-muted);
}

.legal-article a {
    color: var(--text-color);
    text-decoration: underline;
    text-underline-offset: 0.2em;
}

.legal-date {
    margin-top: 4rem;
    text-align: right;
}

/* Animations */
.js .fade-up {
    opacity: 0;
    transform: translateY(30px);
    transition: opacity 0.8s ease-out, transform 0.8s ease-out;
}

.js .fade-up.visible {
    opacity: 1;
    transform: translateY(0);
}

/* Responsive */
@media (max-width: 768px) {
    .header,
    .header.scrolled {
        padding: 0.9rem 0;
        background: rgba(5, 5, 5, 0.94);
        border-bottom: 1px solid var(--border-color);
    }

    .header-container {
        padding: 0 1rem;
    }

    .js .nav-toggle {
        display: inline-flex;
        align-items: center;
    }

    .nav {
        position: absolute;
        top: calc(100% + 1px);
        right: 1rem;
        width: min(18rem, calc(100vw - 2rem));
        padding: 0.75rem;
        background: rgba(17, 17, 17, 0.98);
        border: 1px solid var(--border-color);
        border-radius: 8px;
    }

    .js .nav:not(.is-open) {
        display: none;
    }

    .nav-list {
        flex-direction: column;
        align-items: stretch;
        gap: 0.25rem;
    }

    .nav-link {
        display: block;
        padding: 0.8rem 1rem;
    }

    .btn-contact {
        margin-top: 0.25rem;
        text-align: center;
    }

    .hero {
        min-height: 100svh;
        padding: 7rem 1.25rem 4rem;
    }

    .hero-title {
        font-size: clamp(2.5rem, 12vw, 4rem);
    }

    .hero-actions {
        flex-direction: column;
    }

    .section {
        padding: 5rem 0;
    }

    .section-container {
        padding: 0 1.25rem;
    }

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

    .company-box {
        padding: 2rem 1.25rem;
    }

    .company-list {
        grid-template-columns: 1fr;
        gap: 0.4rem;
    }

    .company-list dt {
        padding-top: 1rem;
        border-bottom: 0;
    }

    .company-list dt:first-child {
        padding-top: 0;
    }

    .company-list dd {
        padding-bottom: 1rem;
        overflow-wrap: anywhere;
    }

    .contact-box {
        padding: 4rem 1.25rem;
    }

    .service-related {
        grid-template-columns: 1fr;
    }

    .contact-text br {
        display: none;
    }
}

@media (prefers-reduced-motion: reduce) {
    html {
        scroll-behavior: auto;
    }

    *,
    *::before,
    *::after {
        scroll-behavior: auto !important;
        transition-duration: 0.01ms !important;
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
    }

    .js .fade-up {
        opacity: 1;
        transform: none;
    }
}

.service-related:hover,
.service-related:focus-visible {
    border-top-color: var(--accent-color);
}

.service-related:hover .service-related-status,
.service-related:focus-visible .service-related-status {
    color: var(--text-color);
}

/* Contact Form Styles */
.contact-form {
    margin-top: 2rem;
    display: flex;
    flex-direction: column;
    gap: 1.25rem;
    text-align: left;
    max-width: 540px;
    margin-left: auto;
    margin-right: auto;
}

.form-group {
    display: flex;
    flex-direction: column;
    gap: 0.4rem;
}

.form-label {
    font-size: 0.9rem;
    font-weight: 500;
    color: var(--text-color);
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.badge-required {
    font-size: 0.7rem;
    background: #ff5252;
    color: #fff;
    padding: 0.15rem 0.4rem;
    border-radius: 4px;
    font-weight: 600;
}

.form-input,
.form-textarea {
    width: 100%;
    padding: 0.8rem 1rem;
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.15);
    border-radius: 8px;
    color: #fff;
    font-family: inherit;
    font-size: 0.95rem;
    transition: border-color 0.2s, background 0.2s, box-shadow 0.2s;
    outline: none;
}

.form-input:focus,
.form-textarea:focus {
    border-color: var(--accent-color, #4f9cf9);
    background: rgba(255, 255, 255, 0.08);
    box-shadow: 0 0 0 3px rgba(79, 156, 249, 0.2);
}

.form-input::placeholder,
.form-textarea::placeholder {
    color: rgba(255, 255, 255, 0.4);
}

.btn-submit {
    margin-top: 0.5rem;
    width: 100%;
    padding: 1rem;
    font-size: 1.05rem;
    font-weight: 600;
    cursor: pointer;
}

.form-note {
    margin-top: 1rem;
    font-size: 0.85rem;
    color: rgba(255, 255, 255, 0.6);
    text-align: center;
}
