/* Reset & Base */
*, *::before, *::after {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

:root {
    --color-bg: #0a0a0a;
    --color-bg-elevated: #141414;
    --color-bg-card: #1a1a1a;
    --color-text: #ffffff;
    --color-text-muted: #888888;
    --color-accent: #c9a962;
    --color-accent-hover: #dfc07a;
    --color-border: #2a2a2a;
    --font-display: 'Playfair Display', Georgia, serif;
    --font-body: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
}

html {
    scroll-behavior: smooth;
}

body {
    font-family: var(--font-body);
    background-color: var(--color-bg);
    color: var(--color-text);
    line-height: 1.6;
    font-weight: 300;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 24px;
}

/* Typography */
h1, h2, h3 {
    font-family: var(--font-display);
    font-weight: 600;
    line-height: 1.2;
}

h1 {
    font-size: clamp(2.5rem, 6vw, 4.5rem);
    letter-spacing: -0.02em;
}

h2 {
    font-size: clamp(2rem, 4vw, 3rem);
    letter-spacing: -0.01em;
}

h3 {
    font-size: 1.25rem;
    font-weight: 600;
}

/* Buttons */
.btn {
    display: inline-block;
    padding: 16px 32px;
    font-family: var(--font-body);
    font-size: 0.875rem;
    font-weight: 500;
    text-decoration: none;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    border: none;
    cursor: pointer;
    transition: all 0.3s ease;
}

.btn-primary {
    background-color: var(--color-accent);
    color: var(--color-bg);
}

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

.btn-full {
    width: 100%;
}

/* Section Label */
.section-label {
    font-size: 0.75rem;
    font-weight: 500;
    text-transform: uppercase;
    letter-spacing: 0.2em;
    color: var(--color-accent);
    margin-bottom: 16px;
}

/* Navigation */
.nav {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 24px 48px;
    z-index: 100;
}

.logo {
    font-family: var(--font-display);
    font-size: 1.25rem;
    font-weight: 700;
    letter-spacing: 0.1em;
}

.logo span {
    font-weight: 400;
    color: var(--color-accent);
}

.nav-cta {
    font-size: 0.75rem;
    font-weight: 500;
    text-transform: uppercase;
    letter-spacing: 0.15em;
    color: var(--color-text);
    text-decoration: none;
    padding: 12px 24px;
    border: 1px solid var(--color-border);
    transition: all 0.3s ease;
}

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

/* Hero Section */
.hero {
    position: relative;
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    background: linear-gradient(135deg, var(--color-bg) 0%, #0f0f0f 50%, #0a0a0a 100%);
    overflow: hidden;
}

.hero::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: radial-gradient(circle at 50% 50%, rgba(201, 169, 98, 0.03) 0%, transparent 50%);
}

.hero-content {
    position: relative;
    z-index: 1;
    max-width: 800px;
    padding: 0 24px;
}

.hero-tagline {
    font-size: 0.75rem;
    font-weight: 500;
    text-transform: uppercase;
    letter-spacing: 0.3em;
    color: var(--color-accent);
    margin-bottom: 24px;
}

.hero h1 {
    margin-bottom: 24px;
}

.hero-subtitle {
    font-size: 1.25rem;
    color: var(--color-text-muted);
    margin-bottom: 48px;
}

.hero-subtitle em {
    color: var(--color-text);
    font-style: italic;
}

.hero-scroll {
    position: absolute;
    bottom: 48px;
    left: 50%;
    transform: translateX(-50%);
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 12px;
}

.hero-scroll span {
    font-size: 0.625rem;
    text-transform: uppercase;
    letter-spacing: 0.2em;
    color: var(--color-text-muted);
}

.scroll-line {
    width: 1px;
    height: 60px;
    background: linear-gradient(to bottom, var(--color-accent), transparent);
    animation: scrollPulse 2s ease-in-out infinite;
}

@keyframes scrollPulse {
    0%, 100% { opacity: 0.3; }
    50% { opacity: 1; }
}

/* Services Section */
.services {
    padding: 120px 0;
    background-color: var(--color-bg-elevated);
}

.services h2 {
    margin-bottom: 64px;
}

.services-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 32px;
}

.service-card {
    padding: 40px;
    background-color: var(--color-bg-card);
    border: 1px solid var(--color-border);
    transition: all 0.3s ease;
}

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

.service-number {
    font-family: var(--font-display);
    font-size: 3rem;
    font-weight: 700;
    color: var(--color-border);
    margin-bottom: 24px;
    transition: color 0.3s ease;
}

.service-card:hover .service-number {
    color: var(--color-accent);
}

.service-card h3 {
    margin-bottom: 16px;
}

.service-card p {
    color: var(--color-text-muted);
    font-size: 0.9375rem;
}

/* About Section */
.about {
    padding: 120px 0;
    background-color: var(--color-bg);
}

.about-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 80px;
    align-items: center;
}

.about-content h2 {
    margin-bottom: 32px;
}

.about-content p {
    color: var(--color-text-muted);
    margin-bottom: 16px;
    font-size: 1.0625rem;
}

.about-stats {
    display: flex;
    gap: 48px;
    margin-top: 48px;
    padding-top: 48px;
    border-top: 1px solid var(--color-border);
}

.stat {
    display: flex;
    flex-direction: column;
}

.stat-number {
    font-family: var(--font-display);
    font-size: 2.5rem;
    font-weight: 700;
    color: var(--color-accent);
}

.stat-label {
    font-size: 0.75rem;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    color: var(--color-text-muted);
    margin-top: 8px;
}

.about-image {
    display: flex;
    justify-content: center;
    align-items: center;
}

.portrait {
    width: 100%;
    max-width: 400px;
    aspect-ratio: 4/5;
    object-fit: cover;
    border: 1px solid var(--color-border);
    filter: grayscale(20%);
    transition: all 0.3s ease;
}

.portrait:hover {
    border-color: var(--color-accent);
    filter: grayscale(0%);
}

/* Contact Section */
.contact {
    padding: 120px 0;
    background-color: var(--color-bg-elevated);
}

.contact-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 80px;
}

.contact-info h2 {
    margin-bottom: 24px;
}

.contact-info > p {
    color: var(--color-text-muted);
    margin-bottom: 48px;
}

.contact-details {
    display: flex;
    flex-direction: column;
    gap: 32px;
}

.contact-item {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.contact-label {
    font-size: 0.75rem;
    text-transform: uppercase;
    letter-spacing: 0.15em;
    color: var(--color-accent);
}

.contact-value {
    font-size: 1.125rem;
}

.classified {
    font-size: 0.875rem;
    color: var(--color-text-muted);
    font-style: italic;
}

/* Contact Form */
.contact-form-wrapper {
    background-color: var(--color-bg-card);
    border: 1px solid var(--color-border);
    padding: 48px;
}

.contact-form {
    display: flex;
    flex-direction: column;
    gap: 24px;
}

.form-group {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.form-group label {
    font-size: 0.75rem;
    text-transform: uppercase;
    letter-spacing: 0.15em;
    color: var(--color-text-muted);
}

.form-group input,
.form-group select,
.form-group textarea {
    padding: 16px;
    background-color: var(--color-bg);
    border: 1px solid var(--color-border);
    color: var(--color-text);
    font-family: var(--font-body);
    font-size: 1rem;
    transition: border-color 0.3s ease;
}

.form-group input::placeholder,
.form-group textarea::placeholder {
    color: var(--color-text-muted);
}

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

.form-group select {
    cursor: pointer;
    appearance: none;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 12 12'%3E%3Cpath fill='%23888888' d='M6 8L1 3h10z'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 16px center;
}

.form-group select option {
    background-color: var(--color-bg-card);
}

.form-group textarea {
    resize: vertical;
    min-height: 120px;
}

.form-disclaimer {
    font-size: 0.75rem;
    color: var(--color-text-muted);
    text-align: center;
    font-style: italic;
}

/* Footer */
.footer {
    padding: 64px 0;
    background-color: var(--color-bg);
    border-top: 1px solid var(--color-border);
}

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

.footer .logo {
    margin-bottom: 16px;
}

.footer-tagline {
    color: var(--color-text-muted);
    font-style: italic;
    margin-bottom: 24px;
}

.footer-copy {
    font-size: 0.75rem;
    color: var(--color-text-muted);
}

.footer-joke {
    display: inline-block;
    margin-top: 16px;
    font-size: 0.625rem;
    color: var(--color-text-muted);
    text-decoration: none;
    opacity: 0.5;
    transition: opacity 0.3s ease;
}

.footer-joke:hover {
    opacity: 1;
    color: var(--color-accent);
}

/* Responsive */
@media (max-width: 968px) {
    .about-grid,
    .contact-grid {
        grid-template-columns: 1fr;
        gap: 48px;
    }

    .about-image {
        order: -1;
    }

    .portrait {
        max-width: 300px;
        margin: 0 auto;
    }

    .about-stats {
        justify-content: space-between;
    }
}

@media (max-width: 768px) {
    .nav {
        padding: 16px 24px;
    }

    .nav-cta {
        padding: 8px 16px;
        font-size: 0.625rem;
    }

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

    .about-stats {
        flex-direction: column;
        gap: 24px;
    }

    .contact-form-wrapper {
        padding: 32px 24px;
    }
}

@media (max-width: 480px) {
    .hero-scroll {
        display: none;
    }

    .section-label {
        font-size: 0.625rem;
    }

    .service-card {
        padding: 32px 24px;
    }
}

/* Dossier Overlay */
.dossier-overlay {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.97);
    z-index: 1000;
    display: none;
    align-items: center;
    justify-content: center;
    opacity: 0;
    transition: opacity 0.3s ease;
}

.dossier-overlay.active {
    display: flex;
    opacity: 1;
}

.dossier-loading {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 24px;
}

.dossier-overlay.loaded .dossier-loading {
    display: none;
}

.loading-text {
    font-family: 'Courier New', monospace;
    font-size: 1.25rem;
    color: #00ff00;
    letter-spacing: 0.1em;
}

.loading-dots::after {
    content: '';
    animation: dots 1.5s steps(4, end) infinite;
}

@keyframes dots {
    0%, 20% { content: ''; }
    40% { content: '.'; }
    60% { content: '..'; }
    80%, 100% { content: '...'; }
}

.loading-bar {
    width: 300px;
    height: 4px;
    background: #1a1a1a;
    border: 1px solid #00ff00;
    overflow: hidden;
}

.loading-progress {
    width: 0%;
    height: 100%;
    background: #00ff00;
    animation: loadProgress 2s ease-out forwards;
}

@keyframes loadProgress {
    0% { width: 0%; }
    100% { width: 100%; }
}

.dossier-content {
    display: none;
    flex-direction: column;
    max-width: 600px;
    width: 90%;
    max-height: 90vh;
    overflow-y: auto;
    background: linear-gradient(135deg, #0a0a0a 0%, #111 100%);
    border: 1px solid #333;
    padding: 48px;
    position: relative;
    font-family: 'Courier New', monospace;
    animation: dossierReveal 0.5s ease-out;
}

.dossier-overlay.loaded .dossier-content {
    display: flex;
}

@keyframes dossierReveal {
    0% {
        opacity: 0;
        transform: scale(0.9) translateY(20px);
    }
    100% {
        opacity: 1;
        transform: scale(1) translateY(0);
    }
}

.dossier-stamp {
    position: absolute;
    top: 40px;
    right: 30px;
    font-size: 2.5rem;
    font-weight: 700;
    color: rgba(200, 0, 0, 0.7);
    border: 4px solid rgba(200, 0, 0, 0.7);
    padding: 8px 16px;
    transform: rotate(12deg);
    letter-spacing: 0.1em;
    pointer-events: none;
    animation: stampReveal 0.3s ease-out 0.3s both;
}

@keyframes stampReveal {
    0% {
        opacity: 0;
        transform: rotate(12deg) scale(2);
    }
    100% {
        opacity: 1;
        transform: rotate(12deg) scale(1);
    }
}

.dossier-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding-bottom: 16px;
    border-bottom: 1px solid #333;
    margin-bottom: 24px;
}

.dossier-logo {
    font-size: 0.75rem;
    letter-spacing: 0.2em;
    color: var(--color-accent);
}

.dossier-doc-id {
    font-size: 0.75rem;
    color: #666;
}

.dossier-title {
    font-size: 1.5rem;
    letter-spacing: 0.3em;
    text-align: center;
    margin-bottom: 32px;
    color: #fff;
}

.dossier-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 24px;
    margin-bottom: 32px;
}

.dossier-field {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.field-label {
    font-size: 0.625rem;
    letter-spacing: 0.2em;
    color: #666;
}

.field-value {
    font-size: 1rem;
    color: #00ff00;
}

.codename-value {
    font-size: 1.5rem;
    color: var(--color-accent);
    text-transform: uppercase;
}

.dossier-section {
    margin-bottom: 24px;
}

.skills-list {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-top: 12px;
}

.skill-tag {
    padding: 6px 12px;
    background: rgba(0, 255, 0, 0.1);
    border: 1px solid #00ff00;
    font-size: 0.75rem;
    color: #00ff00;
    letter-spacing: 0.1em;
}

.mission-brief {
    margin-top: 12px;
    padding: 16px;
    background: #0a0a0a;
    border-left: 3px solid var(--color-accent);
    font-size: 0.875rem;
    line-height: 1.8;
    color: #aaa;
}

.redacted {
    background: #fff;
    color: #fff;
    padding: 0 4px;
    margin: 0 2px;
}

.assignment-text {
    margin-top: 12px;
    font-size: 1rem;
    color: #00ff00;
    padding: 16px;
    border: 1px dashed #00ff00;
    text-align: center;
    letter-spacing: 0.05em;
    animation: pulse 2s ease-in-out infinite;
}

@keyframes pulse {
    0%, 100% { opacity: 1; }
    50% { opacity: 0.7; }
}

.dossier-status {
    display: flex;
    align-items: center;
    gap: 12px;
    justify-content: center;
    margin: 24px 0;
    font-size: 0.875rem;
    color: #00ff00;
}

.status-indicator {
    width: 10px;
    height: 10px;
    background: #00ff00;
    border-radius: 50%;
    animation: blink 1s ease-in-out infinite;
}

@keyframes blink {
    0%, 100% { opacity: 1; }
    50% { opacity: 0.3; }
}

.dossier-close {
    background: transparent;
    border: 1px solid #c00;
    color: #c00;
    padding: 16px 32px;
    font-family: 'Courier New', monospace;
    font-size: 0.875rem;
    letter-spacing: 0.1em;
    cursor: pointer;
    transition: all 0.3s ease;
    margin-top: 16px;
}

.dossier-close:hover {
    background: #c00;
    color: #fff;
}

/* Self-Destruct Sequence */
.terminated-message {
    display: none;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 16px;
}

.terminated-text {
    font-family: 'Courier New', monospace;
    font-size: 2rem;
    color: #c00;
    letter-spacing: 0.2em;
    animation: terminatedPulse 0.5s ease-in-out infinite;
}

.terminated-sub {
    font-family: 'Courier New', monospace;
    font-size: 0.875rem;
    color: #666;
    letter-spacing: 0.1em;
}

@keyframes terminatedPulse {
    0%, 100% { opacity: 1; }
    50% { opacity: 0.5; }
}

/* Glitch Phase */
.dossier-overlay.glitching .dossier-content {
    animation: glitch 0.1s ease-in-out infinite;
}

@keyframes glitch {
    0% {
        transform: translate(0);
        filter: hue-rotate(0deg);
    }
    20% {
        transform: translate(-5px, 5px);
        filter: hue-rotate(90deg);
    }
    40% {
        transform: translate(5px, -5px);
        filter: hue-rotate(180deg);
    }
    60% {
        transform: translate(-5px, -5px);
        filter: hue-rotate(270deg);
    }
    80% {
        transform: translate(5px, 5px);
        filter: hue-rotate(360deg);
    }
    100% {
        transform: translate(0);
        filter: hue-rotate(0deg);
    }
}

.dossier-overlay.glitching .dossier-content::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: repeating-linear-gradient(
        0deg,
        rgba(0, 0, 0, 0.1),
        rgba(0, 0, 0, 0.1) 1px,
        transparent 1px,
        transparent 2px
    );
    pointer-events: none;
    animation: scanlines 0.1s linear infinite;
}

@keyframes scanlines {
    0% { transform: translateY(0); }
    100% { transform: translateY(4px); }
}

/* Burning Phase */
.dossier-overlay.burning .dossier-content {
    animation: burn 0.6s ease-out forwards;
}

@keyframes burn {
    0% {
        opacity: 1;
        filter: brightness(1) saturate(1);
        transform: scale(1);
    }
    30% {
        filter: brightness(2) saturate(2) sepia(1);
    }
    60% {
        filter: brightness(3) saturate(0) sepia(1);
        transform: scale(1.02);
    }
    100% {
        opacity: 0;
        filter: brightness(0) saturate(0);
        transform: scale(0.95);
    }
}

/* Terminated Phase */
.dossier-overlay.terminated .dossier-content {
    display: none;
}

.dossier-overlay.terminated .terminated-message {
    display: flex;
    animation: fadeIn 0.3s ease-out;
}

@keyframes fadeIn {
    0% { opacity: 0; }
    100% { opacity: 1; }
}

@media (max-width: 600px) {
    .dossier-content {
        padding: 32px 24px;
    }

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

    .dossier-stamp {
        font-size: 1.5rem;
        top: 20px;
        right: 15px;
    }
}
