:root {
    --bg-color: #0a0a0a;
    --surface-1: #141414;
    --surface-2: #1f1f1f;
    --text-primary: #ffffff;
    --text-secondary: #a0a0a0;
    --accent: #6d28d9;
    /* Deep Purple */
    --accent-glow: #8b5cf6;
    --white: #ffffff;

    --font-heading: 'Inter', sans-serif;
    --font-body: 'Noto Sans JP', sans-serif;

    --container-width: 1200px;
    --spacing-sm: 1rem;
    --spacing-md: 2rem;
    --spacing-lg: 4rem;
    --spacing-xl: 8rem;

    --transition: all 0.3s cubic-bezier(0.25, 0.46, 0.45, 0.94);
}

/* Canvas Background */
#bg-canvas {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 0;
    /* Changed from -1 to 0 to be safer */
    pointer-events: none;
    opacity: 0.6;
}

/* Ensure content sits above canvas */
main,
footer {
    position: relative;
    z-index: 1;
}

/* Custom Cursor */
body {
    cursor: none;
    /* Hide default cursor */
}

a,
button,
input,
textarea {
    cursor: none;
    /* Ensure it stays hidden on interactive elements */
}

.cursor-dot {
    width: 8px;
    height: 8px;
    background-color: var(--white);
    border-radius: 50%;
    position: fixed;
    top: 0;
    left: 0;
    transform: translate(-50%, -50%);
    /* Start centered on 0,0 */
    pointer-events: none;
    z-index: 9999;
    mix-blend-mode: difference;
    transition: width 0.3s, height 0.3s, background-color 0.3s;
}

.cursor-outline {
    width: 40px;
    height: 40px;
    border: 1px solid rgba(255, 255, 255, 0.5);
    border-radius: 50%;
    position: fixed;
    top: 0;
    left: 0;
    transform: translate(-50%, -50%);
    pointer-events: none;
    z-index: 9998;
    mix-blend-mode: difference;
    transition: width 0.3s, height 0.3s, background-color 0.3s, border-color 0.3s;
    /* Transformation handled in JS for lag effect */
}

.cursor-hover {
    width: 60px;
    height: 60px;
    background-color: rgba(255, 255, 255, 0.1);
    border-color: transparent;
}

.cursor-hover-dot {
    width: 4px;
    height: 4px;
}

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

html {
    scroll-behavior: smooth;
}

body {
    background-color: var(--bg-color);
    color: var(--text-primary);
    font-family: var(--font-body);
    line-height: 1.6;
    font-size: 16px;
    overflow-x: hidden;
}

/* Utilities */
.container {
    max-width: var(--container-width);
    margin: 0 auto;
    padding: 0 var(--spacing-md);
}

.section {
    padding: var(--spacing-xl) 0;
}

.section-title {
    font-family: var(--font-heading);
    font-size: 2.5rem;
    font-weight: 800;
    margin-bottom: var(--spacing-sm);
    letter-spacing: -0.02em;
}

.section-subtitle {
    font-size: 1.25rem;
    color: var(--text-secondary);
    margin-bottom: var(--spacing-lg);
}

.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 1rem 2rem;
    font-family: var(--font-heading);
    font-weight: 600;
    text-decoration: none;
    border-radius: 4px;
    transition: var(--transition);
    cursor: pointer;
    border: none;
    font-size: 1rem;
}

.btn--primary {
    background: var(--accent);
    color: var(--white);
    box-shadow: 0 0 20px rgba(109, 40, 217, 0.3);
}

.btn--primary:hover {
    background: var(--accent-glow);
    box-shadow: 0 0 30px rgba(139, 92, 246, 0.5);
    transform: translateY(-2px);
}

.btn--outline {
    background: transparent;
    border: 1px solid var(--white);
    color: var(--white);
    margin-left: 1rem;
}

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

/* Header */
.header {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    z-index: 1000;
    padding: 1.5rem 0;
    background: rgba(10, 10, 10, 0.8);
    backdrop-filter: blur(10px);
    transition: var(--transition);
}

.header__container {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.logo {
    font-family: var(--font-heading);
    font-size: 1.5rem;
    font-weight: 800;
    text-decoration: none;
    color: var(--white);
    letter-spacing: -0.05em;
}

.logo__dot {
    color: var(--accent);
}

.nav__list {
    display: flex;
    list-style: none;
    gap: 2rem;
    align-items: center;
}

.nav__link {
    text-decoration: none;
    color: var(--text-secondary);
    font-family: var(--font-heading);
    font-weight: 500;
    font-size: 0.9rem;
    transition: var(--transition);
}

.nav__link:hover {
    color: var(--white);
}

.nav__link--cta {
    padding: 0.5rem 1.25rem;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 100px;
    color: var(--white);
}

.nav__link--cta:hover {
    background: var(--white);
    color: var(--bg-color);
}

/* Hero */
.hero {
    height: 100vh;
    display: flex;
    align-items: center;
    position: relative;
    padding-top: 80px;
}

.hero__container {
    position: relative;
    z-index: 2;
}

.hero__title {
    font-family: var(--font-heading);
    font-size: 5rem;
    line-height: 1.1;
    font-weight: 800;
    letter-spacing: -0.04em;
    margin-bottom: 2rem;
    display: flex;
    flex-direction: column;
}

.hero__line {
    display: block;
    background: linear-gradient(to right, #fff, #aaa);
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
}

.hero__subtitle {
    font-size: 1.5rem;
    color: var(--text-secondary);
    max-width: 600px;
    margin-bottom: 3rem;
}

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

.service-card {
    background: rgba(20, 20, 20, 0.7);
    /* Semi-transparent */
    backdrop-filter: blur(10px);
    padding: 3rem;
    border-radius: 1rem;
    border: 1px solid rgba(255, 255, 255, 0.05);
    transition: var(--transition);
}

/* ... */
/* Process */
.process__steps {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 2rem;
    margin-top: 3rem;
}

.process__step {
    background: rgba(20, 20, 20, 0.7);
    /* Semi-transparent */
    backdrop-filter: blur(10px);
    padding: 2.5rem;
    border-radius: 1rem;
    position: relative;
    border: 1px solid rgba(255, 255, 255, 0.05);
    transition: var(--transition);
}

/* ... */
/* Target */
.target__box {
    background: linear-gradient(145deg, rgba(20, 20, 20, 0.8), rgba(31, 31, 31, 0.8));
    /* Semi-transparent gradient */
    backdrop-filter: blur(10px);
    padding: 4rem;
    border-radius: 2rem;
    border: 1px solid rgba(255, 255, 255, 0.05);
    max-width: 800px;
    margin: 0 auto;
    position: relative;
}

.service-card:hover {
    transform: translateY(-5px);
    background: var(--surface-2);
    border-color: var(--accent);
}

.service-card__icon {
    font-size: 2.5rem;
    margin-bottom: 1.5rem;
}

.service-card__title {
    font-family: var(--font-heading);
    font-size: 1.5rem;
    margin-bottom: 1rem;
}

.service-card__desc {
    color: var(--text-secondary);
}

/* Concept */
.concept__content {
    max-width: 800px;
    margin: 0 auto;
}

.concept__text {
    font-size: 1.1rem;
    line-height: 2;
    color: var(--text-secondary);
    margin-bottom: 2rem;
}

.concept .section-title {
    text-align: center;
    font-size: 4rem;
    opacity: 0.1;
    margin-bottom: 3rem;
}

/* Process */
.process__steps {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 2rem;
    margin-top: 3rem;
}

.process__step {
    background: rgba(20, 20, 20, 0.7);
    backdrop-filter: blur(10px);
    padding: 2.5rem;
    border-radius: 1rem;
    position: relative;
    border: 1px solid rgba(255, 255, 255, 0.05);
    transition: var(--transition);
}

.process__step:hover {
    background: var(--surface-2);
    border-color: var(--accent);
    transform: translateY(-5px);
}

.process__number {
    font-size: 4rem;
    font-weight: 800;
    color: var(--accent);
    opacity: 0.1;
    position: absolute;
    top: 0.5rem;
    right: 1.5rem;
    font-family: var(--font-heading);
}

.process__title {
    font-family: var(--font-heading);
    font-size: 1.4rem;
    margin-bottom: 1rem;
    color: var(--white);
    position: relative;
    z-index: 1;
}

.process__desc {
    color: var(--text-secondary);
    font-size: 0.95rem;
    position: relative;
    z-index: 1;
}

/* Target */
.target__box {
    background: linear-gradient(145deg, rgba(20, 20, 20, 0.8), rgba(31, 31, 31, 0.8));
    backdrop-filter: blur(10px);
    padding: 4rem;
    border-radius: 2rem;
    border: 1px solid rgba(255, 255, 255, 0.05);
    max-width: 800px;
    margin: 0 auto;
    position: relative;
}

.target__box::before {
    content: '';
    position: absolute;
    top: -1px;
    left: -1px;
    right: -1px;
    bottom: -1px;
    border-radius: 2rem;
    padding: 1px;
    background: linear-gradient(45deg, transparent, var(--accent), transparent);
    -webkit-mask: linear-gradient(#fff 0 0) content-box, linear-gradient(#fff 0 0);
    mask: linear-gradient(#fff 0 0) content-box, linear-gradient(#fff 0 0);
    -webkit-mask-composite: xor;
    mask-composite: exclude;
    pointer-events: none;
    opacity: 0.5;
}

.target__title {
    text-align: center;
    margin-bottom: 3rem;
    font-family: var(--font-heading);
    font-size: 1.8rem;
}

.target__list {
    list-style: none;
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
}

.target__list li {
    font-size: 1.1rem;
    padding-left: 2.5rem;
    position: relative;
    color: var(--text-primary);
}

.target__list li::before {
    content: '✓';
    color: var(--accent);
    font-weight: bold;
    position: absolute;
    left: 0;
    top: 0;
    font-size: 1.2rem;
}

/* Message */
.message__content {
    text-align: center;
    max-width: 700px;
    margin: 0 auto;
    padding: 4rem 0;
}

.message__title {
    font-size: 2.5rem;
    margin-bottom: 2rem;
    font-family: var(--font-heading);
    background: linear-gradient(to right, #fff, #aaa);
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
}

.message__text {
    font-size: 1.1rem;
    color: var(--text-secondary);
    line-height: 2;
}

/* Works */
.works__grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(350px, 1fr));
    gap: 2rem;
}

.work-item {
    position: relative;
}

.work-item__image {
    width: 100%;
    height: 300px;
    object-fit: cover;
    border-radius: 0.5rem;
    margin-bottom: 1rem;
    transition: var(--transition);
}

.work-item:hover .work-item__image {
    transform: scale(1.02);
}

.work-item h4 {
    font-family: var(--font-heading);
    font-size: 1.4rem;
    margin-bottom: 0.5rem;
}

.work-item__category {
    color: var(--accent);
    font-size: 0.85rem;
    font-weight: 600;
    margin-bottom: 1rem;
    display: block;
}

.work-item__desc {
    color: var(--text-secondary);
    font-size: 0.95rem;
    line-height: 1.7;
}

/* Contact */
.contact__container {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 4rem;
}

.email-link {
    display: block;
    font-size: 2rem;
    color: var(--accent);
    text-decoration: none;
    font-weight: 700;
    margin-top: 2rem;
    font-family: var(--font-heading);
}

.form-group {
    margin-bottom: 1.5rem;
}

.form-group label {
    display: block;
    margin-bottom: 0.5rem;
    color: var(--text-secondary);
    font-size: 0.9rem;
}

.form-group input,
.form-group textarea {
    width: 100%;
    padding: 1rem;
    background: var(--surface-1);
    border: 1px solid rgba(255, 255, 255, 0.1);
    color: var(--white);
    border-radius: 4px;
    font-family: var(--font-body);
    font-size: 1rem;
}

.form-group input:focus,
.form-group textarea:focus {
    outline: none;
    border-color: var(--accent);
    background: var(--surface-2);
}

/* Footer */
.footer {
    padding: 3rem 0;
    border-top: 1px solid rgba(255, 255, 255, 0.05);
    margin-top: 4rem;
}

.footer__container {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.footer__brand p {
    color: var(--text-secondary);
    font-size: 0.9rem;
    margin-top: 0.5rem;
}

.footer__social {
    display: flex;
    gap: 1.5rem;
}

.footer__social a {
    color: var(--text-secondary);
    text-decoration: none;
    transition: var(--transition);
}

.footer__social a:hover {
    color: var(--white);
}

/* Mobile */
@media (max-width: 768px) {
    .container {
        padding: 0 1.5rem;
    }

    .hero__title {
        font-size: 3rem;
    }

    .nav {
        display: none;
        /* Implement mobile menu JS later */
    }

    .about__container,
    .contact__container {
        grid-template-columns: 1fr;
    }
}

/* Animations Classes */
.reveal-text {
    opacity: 0;
    transform: translateY(20px);
    animation: fadeInUp 0.8s forwards;
}

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

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

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