/* ================================================
   R€D€Y€$ - Red Team Operations
   CSS Stylesheet (No JavaScript Required)
   ================================================ */

/* CSS Variables */
:root {
    --bg-primary: #0a0a0a;
    --bg-secondary: #111111;
    --bg-tertiary: #1a1a1a;
    --red-primary: #ff0033;
    --red-secondary: #cc0000;
    --red-glow: #ff3333;
    --red-dark: #660000;
    --text-primary: #e0e0e0;
    --text-secondary: #888888;
    --text-dim: #444444;
    --border-color: #333333;
    --font-mono: 'Courier New', 'Lucida Console', Monaco, monospace;
    --font-sans: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
}

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

html {
    scroll-behavior: smooth;
}

body {
    font-family: var(--font-mono);
    background-color: var(--bg-primary);
    color: var(--text-primary);
    line-height: 1.6;
    overflow-x: hidden;
    position: relative;
}

/* Scanline Overlay */
.scanlines {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
    z-index: 9999;
    background: repeating-linear-gradient(
        0deg,
        rgba(0, 0, 0, 0.15),
        rgba(0, 0, 0, 0.15) 1px,
        transparent 1px,
        transparent 2px
    );
    animation: scanlines 0.1s infinite linear;
}

@keyframes scanlines {
    0% { background-position: 0 0; }
    100% { background-position: 0 2px; }
}

/* Selection */
::selection {
    background: var(--red-primary);
    color: var(--bg-primary);
}

/* Links */
a {
    color: var(--red-primary);
    text-decoration: none;
    transition: all 0.3s ease;
}

a:hover {
    color: var(--red-glow);
    text-shadow: 0 0 10px var(--red-primary);
}

/* ================================================
   HEADER & NAVIGATION
   ================================================ */
.header {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    padding: 1rem 2rem;
    background: linear-gradient(180deg, var(--bg-primary) 0%, transparent 100%);
    z-index: 1000;
}

.nav {
    display: flex;
    justify-content: space-between;
    align-items: center;
    max-width: 1400px;
    margin: 0 auto;
}

.logo {
    font-size: 1.5rem;
    font-weight: bold;
    color: var(--red-primary);
    letter-spacing: 0.1em;
}

.nav-links {
    display: flex;
    list-style: none;
    gap: 2rem;
}

.nav-links a {
    font-size: 0.9rem;
    letter-spacing: 0.1em;
    padding: 0.5rem 1rem;
    border: 1px solid transparent;
    transition: all 0.3s ease;
}

.nav-links a:hover {
    border-color: var(--red-primary);
    background: rgba(255, 0, 51, 0.1);
}

/* ================================================
   GLITCH EFFECT
   ================================================ */
.glitch {
    position: relative;
    animation: glitch-skew 1s infinite linear alternate-reverse;
}

.glitch::before,
.glitch::after {
    content: attr(data-text);
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
}

.glitch::before {
    color: #0ff;
    animation: glitch-1 0.5s infinite linear alternate-reverse;
    clip-path: polygon(0 0, 100% 0, 100% 35%, 0 35%);
}

.glitch::after {
    color: #f0f;
    animation: glitch-2 0.5s infinite linear alternate-reverse;
    clip-path: polygon(0 65%, 100% 65%, 100% 100%, 0 100%);
}

@keyframes glitch-1 {
    0% { transform: translate(0); }
    20% { transform: translate(-2px, 2px); }
    40% { transform: translate(-2px, -2px); }
    60% { transform: translate(2px, 2px); }
    80% { transform: translate(2px, -2px); }
    100% { transform: translate(0); }
}

@keyframes glitch-2 {
    0% { transform: translate(0); }
    20% { transform: translate(2px, -2px); }
    40% { transform: translate(2px, 2px); }
    60% { transform: translate(-2px, -2px); }
    80% { transform: translate(-2px, 2px); }
    100% { transform: translate(0); }
}

@keyframes glitch-skew {
    0% { transform: skew(0deg); }
    10% { transform: skew(-0.5deg); }
    20% { transform: skew(0.5deg); }
    30% { transform: skew(0deg); }
    100% { transform: skew(0deg); }
}

/* ================================================
   HERO SECTION
   ================================================ */
.hero {
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 6rem 2rem 4rem;
    position: relative;
    background:
        radial-gradient(ellipse at center, rgba(255, 0, 51, 0.1) 0%, transparent 70%),
        var(--bg-primary);
}

.hero::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background:
        linear-gradient(90deg, transparent 49%, var(--border-color) 49%, var(--border-color) 51%, transparent 51%),
        linear-gradient(0deg, transparent 49%, var(--border-color) 49%, var(--border-color) 51%, transparent 51%);
    background-size: 50px 50px;
    opacity: 0.1;
}

.hero-content {
    text-align: center;
    z-index: 1;
    flex: 1;
}

.hero-title {
    font-size: clamp(3rem, 10vw, 8rem);
    font-weight: bold;
    color: var(--red-primary);
    letter-spacing: 0.2em;
    text-shadow:
        0 0 20px var(--red-primary),
        0 0 40px var(--red-secondary),
        0 0 60px var(--red-dark);
    margin-bottom: 1rem;
}

.hero-subtitle {
    font-size: 1.2rem;
    color: var(--text-secondary);
    letter-spacing: 0.3em;
    margin-bottom: 2rem;
}

.hero-tagline {
    font-size: 1.5rem;
    margin-bottom: 3rem;
}

.bracket {
    color: var(--red-primary);
    font-weight: bold;
}

.tagline-text {
    color: var(--text-primary);
    letter-spacing: 0.2em;
}

.terminal-line {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    background: var(--bg-secondary);
    padding: 1rem 2rem;
    border: 1px solid var(--border-color);
    border-radius: 4px;
    font-size: 0.9rem;
}

.prompt {
    color: var(--red-primary);
}

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

.cursor {
    display: inline-block;
    width: 10px;
    height: 1.2em;
    background: var(--red-primary);
    animation: blink 1s infinite;
}

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

/* Hero Eye */
.hero-eye {
    position: absolute;
    right: 10%;
    top: 50%;
    transform: translateY(-50%);
    opacity: 0.3;
}

.eye-outer {
    width: 150px;
    height: 150px;
    border: 3px solid var(--red-primary);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    animation: pulse-ring 2s infinite;
}

.eye-inner {
    width: 80px;
    height: 80px;
    background: var(--bg-secondary);
    border: 2px solid var(--red-primary);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
}

.pupil {
    width: 30px;
    height: 30px;
    background: var(--red-primary);
    border-radius: 50%;
    box-shadow: 0 0 20px var(--red-primary);
    animation: pulse 2s infinite;
}

@keyframes pulse {
    0%, 100% { transform: scale(1); opacity: 1; }
    50% { transform: scale(1.2); opacity: 0.8; }
}

@keyframes pulse-ring {
    0%, 100% { box-shadow: 0 0 0 0 rgba(255, 0, 51, 0.4); }
    50% { box-shadow: 0 0 0 20px rgba(255, 0, 51, 0); }
}

/* ================================================
   SECTIONS COMMON
   ================================================ */
section {
    padding: 6rem 2rem;
    max-width: 1400px;
    margin: 0 auto;
}

.section-title {
    font-size: 2rem;
    margin-bottom: 3rem;
    letter-spacing: 0.2em;
    display: flex;
    align-items: center;
    gap: 1rem;
}

.section-title .prefix {
    color: var(--red-primary);
}

/* ================================================
   SERVICES SECTION
   ================================================ */
.services {
    background: var(--bg-primary);
}

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

.service-card {
    background: var(--bg-secondary);
    border: 1px solid var(--border-color);
    padding: 2rem;
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
}

.service-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 3px;
    background: var(--red-primary);
    transform: scaleX(0);
    transform-origin: left;
    transition: transform 0.3s ease;
}

.service-card:hover::before {
    transform: scaleX(1);
}

.service-card:hover {
    border-color: var(--red-primary);
    box-shadow: 0 0 30px rgba(255, 0, 51, 0.2);
    transform: translateY(-5px);
}

.service-icon {
    font-size: 2rem;
    color: var(--red-primary);
    margin-bottom: 1rem;
}

.service-card h3 {
    font-size: 1rem;
    letter-spacing: 0.1em;
    margin-bottom: 1rem;
    color: var(--text-primary);
}

.service-card p {
    color: var(--text-secondary);
    font-size: 0.9rem;
    margin-bottom: 1.5rem;
}

.service-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
}

.service-tags span {
    font-size: 0.75rem;
    padding: 0.25rem 0.75rem;
    background: var(--bg-tertiary);
    border: 1px solid var(--border-color);
    color: var(--red-primary);
}

/* ================================================
   ABOUT SECTION
   ================================================ */
.about {
    background: linear-gradient(180deg, var(--bg-primary) 0%, var(--bg-secondary) 100%);
}

.about-content {
    max-width: 800px;
    margin: 0 auto;
}

.terminal-block {
    background: var(--bg-primary);
    border: 1px solid var(--border-color);
    border-radius: 4px;
    overflow: hidden;
}

.terminal-header {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.75rem 1rem;
    background: var(--bg-tertiary);
    border-bottom: 1px solid var(--border-color);
}

.dot {
    width: 12px;
    height: 12px;
    border-radius: 50%;
}

.dot.red { background: #ff5f56; }
.dot.yellow { background: #ffbd2e; }
.dot.green { background: #27ca40; }

.terminal-title {
    margin-left: auto;
    color: var(--text-secondary);
    font-size: 0.8rem;
}

.terminal-body {
    padding: 1.5rem;
    overflow-x: auto;
}

.terminal-body p {
    margin-bottom: 0.25rem;
    display: flex;
    white-space: nowrap;
}

.line-num {
    color: var(--text-dim);
    margin-right: 1rem;
    user-select: none;
    flex-shrink: 0;
}

.stats {
    display: flex;
    flex-direction: column;
    gap: 2rem;
}

.stat-item {
    text-align: center;
    padding: 1.5rem;
    border: 1px solid var(--border-color);
    background: var(--bg-primary);
}

.stat-number {
    display: block;
    font-size: 2.5rem;
    font-weight: bold;
    color: var(--red-primary);
    text-shadow: 0 0 10px var(--red-primary);
}

.stat-label {
    display: block;
    font-size: 0.8rem;
    color: var(--text-secondary);
    letter-spacing: 0.1em;
    margin-top: 0.5rem;
}

/* ================================================
   TEAM SECTION
   ================================================ */
.team {
    background: var(--bg-primary);
}

.team-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 2rem;
}

.member-card {
    background: var(--bg-secondary);
    border: 1px solid var(--border-color);
    padding: 1.5rem;
    transition: all 0.3s ease;
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
}

.member-card:hover {
    border-color: var(--red-primary);
    box-shadow: 0 0 30px rgba(255, 0, 51, 0.2);
    transform: translateY(-5px);
}

.member-avatar {
    margin-bottom: 1rem;
}

.member-avatar pre {
    font-size: 0.5rem;
    line-height: 1;
    color: var(--red-primary);
    text-shadow: 0 0 5px var(--red-primary);
    margin: 0;
    animation: avatar-pulse 3s infinite;
}

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

.member-card:hover .member-avatar pre {
    animation: avatar-glitch 0.3s infinite;
}

@keyframes avatar-glitch {
    0% { transform: translate(0); }
    20% { transform: translate(-1px, 1px); }
    40% { transform: translate(1px, -1px); }
    60% { transform: translate(-1px, -1px); }
    80% { transform: translate(1px, 1px); }
    100% { transform: translate(0); }
}

.member-info {
    width: 100%;
}

.member-handle {
    font-size: 1.2rem;
    color: var(--red-primary);
    letter-spacing: 0.15em;
    margin-bottom: 0.25rem;
    text-shadow: 0 0 10px var(--red-primary);
}

.member-role {
    font-size: 0.85rem;
    color: var(--text-secondary);
    margin-bottom: 1rem;
}

.member-skills {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 0.5rem;
    margin-bottom: 1rem;
}

.member-skills span {
    font-size: 0.7rem;
    padding: 0.2rem 0.6rem;
    background: var(--bg-tertiary);
    border: 1px solid var(--border-color);
    color: var(--red-primary);
}

.member-bio {
    font-size: 0.85rem;
    color: var(--text-secondary);
    line-height: 1.5;
}

/* ================================================
   CONTACT SECTION
   ================================================ */
.contact {
    background: var(--bg-secondary);
}

.contact-content {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 3rem;
}

.contact-info {
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
}

.contact-item {
    display: flex;
    gap: 1rem;
    align-items: baseline;
    padding: 1rem;
    border-left: 2px solid var(--red-primary);
    background: var(--bg-primary);
}

.contact-label {
    color: var(--red-primary);
    font-size: 0.85rem;
    min-width: 80px;
}

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

.contact-value.mono {
    font-family: var(--font-mono);
    letter-spacing: 0.1em;
}

.glitch-hover:hover {
    animation: glitch-text 0.3s infinite;
}

@keyframes glitch-text {
    0% { text-shadow: 2px 0 #0ff, -2px 0 #f0f; }
    25% { text-shadow: -2px 0 #0ff, 2px 0 #f0f; }
    50% { text-shadow: 2px 0 #f0f, -2px 0 #0ff; }
    75% { text-shadow: -2px 0 #f0f, 2px 0 #0ff; }
    100% { text-shadow: 2px 0 #0ff, -2px 0 #f0f; }
}

/* Session Contact Styles */
.session-qr {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    background: var(--bg-primary);
    border: 1px solid var(--border-color);
    padding: 2rem;
}

.qr-image {
    width: 200px;
    height: 200px;
    border: 2px solid var(--red-primary);
    padding: 0.5rem;
    background: white;
}

.qr-label {
    margin-top: 1rem;
    color: var(--text-secondary);
    font-size: 0.8rem;
    letter-spacing: 0.1em;
}

.session-info {
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
}

.session-logo {
    display: flex;
    align-items: center;
    gap: 1rem;
}

.session-title {
    font-size: 1.5rem;
    font-weight: bold;
    color: var(--red-primary);
    letter-spacing: 0.1em;
}

.session-description {
    color: var(--text-secondary);
    font-size: 0.9rem;
    line-height: 1.6;
}

.session-id-box {
    background: var(--bg-primary);
    border: 1px solid var(--border-color);
    padding: 1rem;
}

.session-id-label {
    display: block;
    color: var(--red-primary);
    font-size: 0.75rem;
    margin-bottom: 0.5rem;
}

.session-id {
    display: block;
    font-family: var(--font-mono);
    font-size: 0.7rem;
    color: var(--text-primary);
    word-break: break-all;
    line-height: 1.4;
    background: transparent;
}

.session-download {
    margin-top: 1rem;
}

.download-label {
    color: var(--text-secondary);
    font-size: 0.85rem;
    margin-bottom: 1rem;
}

.download-links {
    display: flex;
    flex-wrap: wrap;
    gap: 0.75rem;
}

.download-btn {
    display: inline-block;
    padding: 0.75rem 1.25rem;
    background: transparent;
    border: 1px solid var(--red-primary);
    color: var(--red-primary);
    font-family: var(--font-mono);
    font-size: 0.85rem;
    text-decoration: none;
    transition: all 0.3s ease;
}

.download-btn:hover {
    background: var(--red-primary);
    color: var(--bg-primary);
    box-shadow: 0 0 15px rgba(255, 0, 51, 0.5);
}

/* ================================================
   FOOTER
   ================================================ */
.footer {
    background: var(--bg-primary);
    border-top: 1px solid var(--border-color);
    padding: 3rem 2rem;
}

.footer-content {
    max-width: 1400px;
    margin: 0 auto;
    display: grid;
    grid-template-columns: auto 1fr auto;
    gap: 2rem;
    align-items: center;
}

.footer-logo {
    font-size: 1.5rem;
    font-weight: bold;
    color: var(--red-primary);
    letter-spacing: 0.1em;
}

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

.footer-text p {
    color: var(--text-secondary);
    font-size: 0.8rem;
    margin-bottom: 0.25rem;
}

.footer-ascii pre {
    color: var(--red-dark);
    font-size: 0.5rem;
    line-height: 1;
    text-align: right;
}

/* ================================================
   RESPONSIVE
   ================================================ */
@media (max-width: 1024px) {
    .hero-eye {
        display: none;
    }

    .about-content {
        grid-template-columns: 1fr;
    }

    .stats {
        flex-direction: row;
        justify-content: center;
    }

    .contact-content {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 768px) {
    .nav {
        flex-direction: column;
        gap: 1rem;
    }

    .nav-links {
        gap: 1rem;
    }

    .hero {
        padding-top: 8rem;
    }

    .hero-title {
        letter-spacing: 0.1em;
    }

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

    .terminal-line {
        flex-wrap: wrap;
        font-size: 0.75rem;
    }

    .footer-content {
        grid-template-columns: 1fr;
        text-align: center;
    }

    .footer-ascii {
        display: none;
    }

    .stats {
        flex-direction: column;
    }

    .stat-item {
        padding: 1rem;
    }

    .stat-number {
        font-size: 2rem;
    }
}

@media (max-width: 480px) {
    .nav-links a {
        font-size: 0.75rem;
        padding: 0.25rem 0.5rem;
    }

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

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

/* ================================================
   ACCESSIBILITY
   ================================================ */
@media (prefers-reduced-motion: reduce) {
    *, *::before, *::after {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
    }

    .scanlines {
        display: none;
    }
}

/* Focus styles for keyboard navigation */
a:focus,
button:focus {
    outline: 2px solid var(--red-primary);
    outline-offset: 2px;
}

/* Print styles */
@media print {
    .scanlines,
    .hero-eye {
        display: none;
    }

    body {
        background: white;
        color: black;
    }

    .glitch::before,
    .glitch::after {
        display: none;
    }
}
