:root {
    --cyan: #00f0ff;
    --magenta: #ff003c;
    --dark-bg: #030a16;
    --hud-bg: rgba(0, 30, 60, 0.4);
    --border-color: rgba(0, 240, 255, 0.3);
    --text-main: #e0f2fe;
    --font-tech: 'Share Tech Mono', monospace;
    --font-thai: 'Kanit', sans-serif;
}

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

body.cyber-theme {
    background-color: var(--dark-bg);
    color: var(--text-main);
    font-family: var(--font-thai);
    overflow-x: hidden;
}

/* Cyber Background Grid */
.cyber-grid {
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    background-image:
        linear-gradient(rgba(0, 240, 255, 0.05) 1px, transparent 1px),
        linear-gradient(90deg, rgba(0, 240, 255, 0.05) 1px, transparent 1px);
    background-size: 30px 30px;
    z-index: -1;
    perspective: 1000px;
    animation: grid-scroll 20s linear infinite;
}

@keyframes grid-scroll {
    from {
        transform: translateY(0);
    }

    to {
        transform: translateY(30px);
    }
}

/* HUD Typography & Utils */
.text-cyan {
    color: var(--cyan);
}

.text-magenta {
    color: var(--magenta);
}

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

.mb-4 {
    margin-bottom: 2rem;
}

.mt-5 {
    margin-top: 4rem;
}

h1,
h2,
h3,
.eng-title {
    font-family: var(--font-tech);
    text-transform: uppercase;
}

.glow-text {
    color: var(--cyan);
    text-shadow: 0 0 10px rgba(0, 240, 255, 0.7);
}

/* Glass HUD Elements */
.glass-hud {
    background: var(--hud-bg);
    backdrop-filter: blur(5px);
    border: 1px solid var(--border-color);
}

/* Navigation */
.hud-nav {
    position: fixed;
    top: 0;
    width: 100%;
    border-top: 0;
    border-left: 0;
    border-right: 0;
    border-bottom: 2px solid var(--cyan);
    z-index: 1000;
}

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

.logo {
    font-size: 1.8rem;
    color: #fff;
    text-decoration: none;
    font-weight: bold;
    letter-spacing: 2px;
}

.logo span {
    color: var(--cyan);
}

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

.nav-links a {
    color: var(--border-color);
    text-decoration: none;
    font-family: var(--font-tech);
    font-size: 1.1rem;
    transition: all 0.3s ease;
}

.nav-links a:hover,
.nav-links a.active {
    color: var(--cyan);
    text-shadow: 0 0 10px var(--cyan);
}

/* Container & Pages */
.page-container {
    max-width: 1200px;
    margin: 120px auto 50px;
    padding: 0 2rem;
    animation: fadeIn 0.8s ease-out;
}

/* Home Section Layout */
.hero-section {
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    padding: 6rem 1rem 2rem;
}

.eng-title {
    font-size: 3.5rem;
    color: #fff;
    margin-bottom: 0.5rem;
    text-shadow: 2px 2px 0px var(--magenta);
}

.thai-title {
    font-family: var(--font-thai);
    font-size: 2rem;
    font-weight: 600;
    margin-bottom: 1rem;
}

.subtitle {
    color: #aaa;
    font-size: 1.1rem;
    margin-bottom: 3rem;
    max-width: 600px;
    margin-inline: auto;
}

/* HUD Scanner View (Replaces Hero Image) */
.scanner-wrapper {
    position: relative;
    max-width: 600px;
    margin: 0 auto 3rem;
    padding: 1rem;
    background: rgba(0, 0, 0, 0.5);
    border: 1px solid rgba(255, 255, 255, 0.1);
}

.detection-img {
    width: 100%;
    display: block;
    mix-blend-mode: screen;
    filter: drop-shadow(0 0 10px var(--cyan));
}

/* Scanner Brackets */
.frame {
    position: absolute;
    width: 30px;
    height: 30px;
    border-color: var(--cyan);
    border-style: solid;
}

.top-left {
    top: -2px;
    left: -2px;
    border-width: 3px 0 0 3px;
}

.top-right {
    top: -2px;
    right: -2px;
    border-width: 3px 3px 0 0;
}

.bottom-left {
    bottom: -2px;
    left: -2px;
    border-width: 0 0 3px 3px;
}

.bottom-right {
    bottom: -2px;
    right: -2px;
    border-width: 0 3px 3px 0;
}

.scanner-laser {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 2px;
    background: var(--cyan);
    box-shadow: 0 0 15px var(--cyan);
    animation: scan 3s linear infinite alternate;
}

@keyframes scan {
    0% {
        top: 10%;
    }

    100% {
        top: 90%;
    }
}

.data-point {
    position: absolute;
    background: rgba(0, 0, 0, 0.8);
    border-left: 2px solid var(--cyan);
    padding: 5px 10px;
    font-family: var(--font-tech);
    font-size: 0.8rem;
    color: var(--cyan);
}

.point-1 {
    top: 20%;
    left: -100px;
    animation: blink 2s infinite;
}

.point-2 {
    top: 50%;
    right: -120px;
    animation: blink 3s infinite 0.5s;
}

.point-3 {
    bottom: 20%;
    left: -140px;
    color: var(--magenta);
    border-color: var(--magenta);
    animation: blink 1.5s infinite 1s;
}

@keyframes blink {

    0%,
    100% {
        opacity: 1;
    }

    50% {
        opacity: 0.5;
    }
}

/* Cyber Button */
.btn-cyber {
    display: inline-block;
    padding: 1rem 3rem;
    font-family: var(--font-tech);
    font-size: 1.2rem;
    color: var(--dark-bg);
    background: var(--cyan);
    text-decoration: none;
    font-weight: bold;
    position: relative;
    clip-path: polygon(10px 0, 100% 0, 100% calc(100% - 10px), calc(100% - 10px) 100%, 0 100%, 0 10px);
    transition: all 0.3s;
}

.btn-cyber:hover {
    background: #fff;
    box-shadow: 0 0 20px var(--cyan);
}

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

.cyber-card {
    padding: 2rem;
    position: relative;
    transition: all 0.3s;
}

.cyber-card:hover {
    border-color: var(--cyan);
    box-shadow: inset 0 0 20px rgba(0, 240, 255, 0.1);
    transform: translateY(-5px);
}

.card-icon {
    width: 50px;
    height: 50px;
    background: rgba(0, 240, 255, 0.1);
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--cyan);
    border-radius: 5px;
    margin-bottom: 1.5rem;
}

.tech-list {
    list-style: none;
    margin-top: 1rem;
}

.logic-flow {
    display: flex;
    align-items: center;
    gap: 10px;
    font-family: var(--font-tech);
    font-size: 1.2rem;
    margin-top: 1rem;
    background: rgba(0, 0, 0, 0.5);
    padding: 10px;
    border-radius: 5px;
}

/* Workflow steps */
.workflow-steps {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 2rem;
    margin-top: 2rem;
}

.w-step {
    padding: 2rem;
    text-align: center;
    position: relative;
}

.step-num {
    display: block;
    font-family: var(--font-tech);
    font-size: 3rem;
    color: rgba(0, 240, 255, 0.2);
}

/* Team Section */
.team-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
    gap: 2rem;
    margin-top: 2rem;
}

.member-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
    padding-bottom: 1rem;
    margin-bottom: 1rem;
}

.member-id {
    font-family: var(--font-tech);
    font-size: 0.9rem;
    color: #888;
}

.tech-role {
    font-family: var(--font-tech);
    margin-bottom: 1rem;
    display: inline-block;
    background: rgba(0, 240, 255, 0.1);
    padding: 5px 10px;
}

.cyber-link {
    color: #fff;
    text-decoration: none;
    border-bottom: 1px dashed var(--cyan);
    display: inline-block;
    margin-top: 1rem;
}

.cyber-link:hover {
    color: var(--cyan);
}

.footer-text {
    color: #666;
    font-family: var(--font-tech);
}

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

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

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

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

    .nav-content {
        flex-direction: column;
        gap: 1rem;
    }

    .workflow-steps {
        grid-template-columns: 1fr;
    }

    .data-point {
        display: none;
    }
}