/* --- 1. Variables & Reset --- */
:root {
    --bg-black: #000000;
    --surface: #0a0a0a;
    --accent: #00FF41;      /* Matrix Green */
    --accent-glow: rgba(0, 255, 65, 0.3);
    --text-main: #FFFFFF;
    --text-muted: #888888;
    --border-color: #222222;
    --font-mono: 'JetBrains Mono', monospace;
}

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

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

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

/* --- 2. Typography --- */
h1, h2, h3 {
    text-transform: uppercase;
    letter-spacing: -1px;
}

a {
    transition: 0.3s ease;
}

/* --- 3. Navbar & Glitch Effect --- */
.navbar {
    padding: 2rem 0;
    border-bottom: 1px solid var(--border-color);
}

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

.logo {
    font-size: 1.8rem;
    font-weight: 800;
    text-decoration: none;
    color: var(--text-main);
    position: relative;
}

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

.glitch:hover::before {
    left: 2px;
    text-shadow: -2px 0 #ff00c1;
    clip: rect(44px, 450px, 56px, 0);
    animation: glitch-anim 5s infinite linear alternate-reverse;
}

.glitch:hover::after {
    left: -2px;
    text-shadow: -2px 0 #00fff9;
    clip: rect(44px, 450px, 56px, 0);
    animation: glitch-anim-2 5s infinite linear alternate-reverse;
}

@keyframes glitch-anim {
    0% { clip: rect(10px, 9999px, 20px, 0); }
    100% { clip: rect(80px, 9999px, 90px, 0); }
}

@keyframes glitch-anim-2 {
    0% { clip: rect(50px, 9999px, 60px, 0); }
    100% { clip: rect(10px, 9999px, 30px, 0); }
}

.nav-links {
    list-style: none;
    display: flex;
    gap: 30px;
    align-items: center;
}

.nav-item {
    text-decoration: none;
    color: var(--text-muted);
    font-size: 0.9rem;
}

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

.nav-cta-btn {
    text-decoration: none;
    color: var(--accent);
    border: 1px solid var(--accent);
    padding: 8px 16px;
    font-size: 0.85rem;
}

.nav-cta-btn:hover {
    background: var(--accent);
    color: var(--bg-black);
    box-shadow: 0 0 15px var(--accent-glow);
}

/* --- 4. Hero Section --- */
.hero-section {
    padding: 120px 0;
    position: relative;
}

.grid-overlay {
    position: absolute;
    top: 0; left: 0; width: 100%; height: 100%;
    background-image: radial-gradient(var(--border-color) 1px, transparent 1px);
    background-size: 30px 30px;
    z-index: -1;
    opacity: 0.5;
}

.main-title {
    font-size: 4rem;
    margin-bottom: 20px;
}

.outline-text {
    color: transparent;
    -webkit-text-stroke: 1px var(--text-main);
}

.hero-description {
    color: var(--text-muted);
    max-width: 600px;
    margin-bottom: 40px;
}

.btn-primary {
    display: inline-block;
    padding: 15px 30px;
    background: var(--accent);
    color: var(--bg-black);
    text-decoration: none;
    font-weight: bold;
}

.btn-outline {
    display: inline-block;
    padding: 15px 30px;
    border: 1px solid var(--text-main);
    color: var(--text-main);
    text-decoration: none;
    margin-left: 20px;
}

/* --- 5. Feature Grid --- */
.feature-grid { padding: 100px 0; }
.feature-grid .container {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 20px;
}

.feature-card {
    background: var(--surface);
    border: 1px solid var(--border-color);
    padding: 40px;
}

.feature-card:hover {
    border-color: var(--accent);
}

.card-num { color: var(--accent); margin-bottom: 10px; font-weight: bold; }

/* --- 6. Footer --- */
/* --- Optimized Footer Styling --- */
.main-footer {
    background-color: #000;
    border-top: 2px solid var(--border-color);
    padding: 80px 0 30px 0;
    margin-top: 100px;
}

.footer-grid {
    display: grid;
    grid-template-columns: 2fr 1fr 1fr;
    gap: 60px;
    padding-bottom: 60px;
}

.footer-logo {
    font-size: 1.4rem;
    font-weight: 800;
    margin-bottom: 1.5rem;
}

.footer-bio {
    color: var(--text-muted);
    font-size: 0.95rem;
    max-width: 350px;
    margin-bottom: 2rem;
}

/* System Status Box */
.status-box {
    display: inline-flex;
    align-items: center;
    background: #0a0a0a;
    border: 1px solid #1a1a1a;
    padding: 10px 18px;
    font-size: 0.75rem;
    letter-spacing: 1px;
}

.pulse-dot {
    height: 8px;
    width: 8px;
    background-color: var(--accent);
    border-radius: 50%;
    margin-right: 12px;
    box-shadow: 0 0 10px var(--accent);
    animation: pulse 2s infinite;
}

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

.status-label { color: #555; margin-right: 8px; }
.status-value { color: var(--accent); font-weight: bold; }

/* Navigation & Lists */
.footer-heading {
    color: var(--text-main);
    font-size: 0.8rem;
    text-transform: uppercase;
    letter-spacing: 2px;
    margin-bottom: 1.5rem;
}

.footer-list {
    list-style: none;
}

.footer-list li {
    margin-bottom: 12px;
}

.footer-list a {
    color: var(--text-muted);
    text-decoration: none;
    font-size: 0.9rem;
    transition: all 0.2s ease;
}

.footer-list a:hover {
    color: var(--accent);
    padding-left: 8px;
}

/* Footer Bottom Bar */
.footer-bottom {
    border-top: 1px solid #111;
    padding-top: 30px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-size: 0.7rem;
    color: #444;
    letter-spacing: 1px;
}

/* Responsive Fix */
@media (max-width: 768px) {
    .footer-grid {
        grid-template-columns: 1fr;
        gap: 40px;
    }
    .footer-bottom {
        flex-direction: column;
        gap: 15px;
        text-align: center;
    }
}

.status-dot {
    height: 8px; width: 8px;
    background: var(--accent);
    border-radius: 50%;
    display: inline-block;
    box-shadow: 0 0 5px var(--accent);
}

/* --- Terminal Form Design --- */
.terminal-form-wrapper {
    max-width: 800px;
    margin: 60px auto;
    border: 2px solid var(--border-color);
    background: #050505;
    box-shadow: 0 20px 50px rgba(0,0,0,0.5);
}

.terminal-header {
    background: #111;
    padding: 10px 20px;
    display: flex;
    align-items: center;
    border-bottom: 1px solid var(--border-color);
}

.terminal-buttons {
    display: flex;
    gap: 8px;
    margin-right: 20px;
}

.dot {
    width: 12px;
    height: 12px;
    border-radius: 50%;
}
.red { background: #ff5f56; }
.yellow { background: #ffbd2e; }
.green { background: #27c93f; }

.terminal-title {
    font-size: 0.75rem;
    color: #555;
    text-transform: uppercase;
    letter-spacing: 1px;
}

.terminal-body {
    padding: 40px;
}

.input-line {
    margin-bottom: 30px;
}

.prompt {
    display: block;
    color: var(--accent);
    margin-bottom: 10px;
    font-size: 0.9rem;
}

.terminal-body input, 
.terminal-body textarea, 
.terminal-body select {
    width: 100%;
    background: transparent;
    border: none;
    border-bottom: 1px solid #222;
    color: #fff;
    font-family: var(--font-mono);
    font-size: 1.1rem;
    padding: 10px 0;
    outline: none;
    transition: 0.3s;
}

.terminal-body input:focus, 
.terminal-body textarea:focus {
    border-bottom: 1px solid var(--accent);
    box-shadow: 0 5px 15px rgba(0, 255, 65, 0.05);
}

/* Style for the select dropdown to keep it high-contrast */
.terminal-body select option {
    background: #000;
    color: #fff;
}

.terminal-submit {
    background: transparent;
    border: 1px solid var(--accent);
    color: var(--accent);
    padding: 15px 30px;
    font-family: var(--font-mono);
    font-weight: bold;
    cursor: pointer;
    text-transform: uppercase;
    transition: 0.3s;
}

.terminal-submit:hover {
    background: var(--accent);
    color: #000;
    box-shadow: 0 0 20px var(--accent-glow);
}

/* --- Services Page Styling --- */
.services-hero {
    padding: 80px 0;
    text-align: center;
    border-bottom: 1px solid var(--border-color);
}

.services-hero h1 {
    font-size: 3rem;
    margin-bottom: 10px;
}

.subtitle {
    color: var(--text-muted);
}

.services-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 30px;
    padding: 60px 0;
}

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

.service-card:hover {
    border-color: var(--accent);
    transform: translateY(-10px);
    box-shadow: 0 10px 30px rgba(0, 255, 65, 0.05);
}

.card-icon {
    font-family: var(--font-mono);
    color: var(--accent);
    font-weight: bold;
    margin-bottom: 20px;
    font-size: 0.9rem;
}

.service-card h3 {
    margin-bottom: 15px;
    font-size: 1.4rem;
}

.service-card p {
    color: var(--text-muted);
    font-size: 0.95rem;
    margin-bottom: 25px;
}

/* Tech Tags Wrapper */
.tech-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    list-style: none;
    padding: 0;
}

.tech-tags li {
    font-size: 0.7rem;
    background: #111;
    color: var(--accent);
    padding: 4px 10px;
    border: 1px solid #222;
    text-transform: uppercase;
}

/* --- Portfolio Styling --- */
.portfolio-hero {
    padding: 80px 0;
    text-align: center;
    border-bottom: 1px solid var(--border-color);
}

.portfolio-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(400px, 1fr));
    gap: 40px;
    padding: 80px 0;
}

.portfolio-item {
    border: 1px solid var(--border-color);
    background: var(--surface);
    transition: 0.3s ease;
}

.portfolio-item:hover {
    border-color: var(--accent);
}

.project-image-placeholder {
    height: 250px;
    background: #0a0a0a;
    display: flex;
    align-items: center;
    justify-content: center;
    border-bottom: 1px solid var(--border-color);
    background-image: linear-gradient(45deg, #0d0d0d 25%, transparent 25%, transparent 50%, #0d0d0d 50%, #0d0d0d 75%, transparent 75%, transparent);
    background-size: 20px 20px;
}

.img-text {
    font-family: var(--font-mono);
    color: #222;
    font-size: 2rem;
    font-weight: 900;
}

.project-content {
    padding: 30px;
}

.project-meta {
    font-size: 0.7rem;
    color: var(--accent);
    letter-spacing: 2px;
    margin-bottom: 10px;
}

.project-tech {
    margin: 20px 0;
    display: flex;
    gap: 10px;
}

.project-tech span {
    font-size: 0.65rem;
    padding: 2px 8px;
    border: 1px solid #333;
    color: var(--text-muted);
}

.view-project {
    display: inline-block;
    color: var(--text-main);
    text-decoration: none;
    font-size: 0.85rem;
    font-weight: bold;
    border-bottom: 1px solid var(--accent);
    padding-bottom: 4px;
    transition: 0.3s;
}

.view-project:hover {
    color: var(--accent);
    border-color: var(--text-main);
}

@media (max-width: 500px) {
    .portfolio-grid {
        grid-template-columns: 1fr;
    }
}

/* --- About Page Styling --- */
.about-hero {
    padding: 100px 0;
    text-align: center;
    border-bottom: 1px solid var(--border-color);
}

.split-layout {
    display: grid;
    grid-template-columns: 1.5fr 1fr;
    gap: 80px;
    padding: 80px 0;
    align-items: center;
}

.accent-title {
    color: var(--accent);
    font-size: 0.9rem;
    margin-bottom: 20px;
}

.text-block p {
    font-size: 1.2rem;
    line-height: 1.8;
    color: var(--text-main);
}

/* Stats Block */
.stats-block {
    display: grid;
    grid-template-columns: 1fr;
    gap: 20px;
}

.stat-item {
    border: 1px solid var(--border-color);
    padding: 30px;
    text-align: center;
}

.stat-value {
    display: block;
    font-size: 2.5rem;
    font-weight: 800;
    color: var(--accent);
}

.stat-label {
    font-size: 0.7rem;
    letter-spacing: 2px;
    color: var(--text-muted);
}

/* Process Grid */
.process-section {
    padding: 100px 0;
    background: #050505;
    border-top: 1px solid var(--border-color);
}

.section-heading {
    text-align: center;
    margin-bottom: 60px;
    font-size: 1.5rem;
}

.process-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 20px;
}

.process-step {
    border: 1px solid var(--border-color);
    padding: 30px;
    transition: 0.3s;
}

.process-step:hover {
    background: var(--accent);
}

.process-step:hover h4, 
.process-step:hover p, 
.process-step:hover .step-num {
    color: #000;
}

.step-num {
    display: block;
    font-size: 0.8rem;
    margin-bottom: 15px;
    color: var(--accent);
}

@media (max-width: 768px) {
    .split-layout { grid-template-columns: 1fr; gap: 40px; }
}

/* --- Success Page Styling --- */
.success-page {
    height: 70vh;
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
}

.success-container {
    padding: 60px;
    border: 1px solid var(--border-color);
    background: #050505;
}

.success-icon-wrapper {
    margin-bottom: 30px;
}

.checkmark {
    width: 80px;
    height: 80px;
    border-radius: 50%;
    display: block;
    stroke-width: 2;
    stroke: var(--accent);
    stroke-miterlimit: 10;
    margin: 0 auto;
    box-shadow: inset 0px 0px 0px var(--accent);
    animation: fill .4s ease-in-out .4s forwards, scale .3s ease-in-out .9s both;
}

.checkmark__circle {
    stroke-dasharray: 166;
    stroke-dashoffset: 166;
    stroke-width: 2;
    stroke-miterlimit: 10;
    stroke: var(--accent);
    fill: none;
    animation: stroke 0.6s cubic-bezier(0.65, 0, 0.45, 1) forwards;
}

.checkmark__check {
    transform-origin: 50% 50%;
    stroke-dasharray: 48;
    stroke-dashoffset: 48;
    animation: stroke 0.3s cubic-bezier(0.65, 0, 0.45, 1) 0.8s forwards;
}

@keyframes stroke { 100% { stroke-dashoffset: 0; } }
@keyframes scale { 0%, 100% { transform: none; } 50% { transform: scale3d(1.1, 1.1, 1); } }

.success-message {
    color: var(--text-muted);
    max-width: 500px;
    margin: 20px auto 40px;
}

.success-details {
    font-family: var(--font-mono);
    font-size: 0.8rem;
    margin-bottom: 40px;
    padding: 15px;
    border: 1px dashed #222;
}

/* --- Bio Section Styles --- */
.bio-grid {
    display: grid;
    grid-template-columns: 2fr 1fr;
    gap: 60px;
    padding: 80px 0;
    align-items: flex-start;
}

.bio-text p {
    margin-bottom: 25px;
    font-size: 1.1rem;
    color: var(--text-muted);
}

.bio-text strong {
    color: var(--text-main);
    border-bottom: 1px solid var(--accent);
}

/* Stats Styling */
.bio-stats {
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.stat-box {
    padding: 25px;
    border: 1px solid var(--border-color);
    background: var(--surface);
    text-align: center;
}

.stat-number {
    display: block;
    font-size: 2.2rem;
    font-weight: 800;
    color: var(--accent);
}

.stat-label {
    font-size: 0.7rem;
    color: #555;
    letter-spacing: 2px;
}

/* Tech Stack Items */
.stack-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(150px, 1fr));
    gap: 15px;
    padding-bottom: 100px;
}

.stack-item {
    border: 1px solid #222;
    padding: 15px;
    text-align: center;
    font-size: 0.8rem;
    background: #050505;
    transition: 0.3s;
}

.stack-item:hover {
    color: #000;
    background: var(--accent);
    border-color: var(--accent);
}

@media (max-width: 768px) {
    .bio-grid { grid-template-columns: 1fr; }
}

/* --- DB Philosophy Styles --- */
.db-philosophy {
    padding: 80px 0;
    background-color: #030303;
}

.terminal-window {
    border: 1px solid var(--border-color);
    background: #000;
    box-shadow: 0 30px 60px rgba(0,0,0,0.6);
}

.terminal-bar {
    background: #111;
    padding: 10px 20px;
    border-bottom: 1px solid var(--border-color);
    font-size: 0.7rem;
    color: #444;
    font-family: var(--font-mono);
}

.terminal-content {
    padding: 50px;
}

.philosophy-intro {
    font-size: 1.2rem;
    color: var(--text-main);
    margin-bottom: 40px;
    max-width: 800px;
}

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

.p-item h4 {
    color: var(--accent);
    margin-bottom: 10px;
    text-transform: uppercase;
    font-size: 1rem;
}

.p-item p {
    font-size: 0.9rem;
    color: var(--text-muted);
    line-height: 1.6;
}

.p-icon {
    display: block;
    font-size: 0.8rem;
    color: #333;
    margin-bottom: 15px;
    font-weight: bold;
}

.highlight-accent {
    border: 2px solid var(--accent) !important;
    background: rgba(0, 255, 65, 0.05) !important;
    box-shadow: 0 0 20px rgba(0, 255, 65, 0.1);
}

.highlight-accent .stat-number {
    text-shadow: 0 0 10px var(--accent);
}

/* --- Culture Section Styles --- */
.culture-section {
    padding: 100px 0;
    border-top: 1px solid var(--border-color);
}

.culture-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
    gap: 30px;
    margin-top: 50px;
}

.culture-card {
    padding: 40px;
    background: #080808;
    border-left: 3px solid #222; /* Minimalist start */
    transition: 0.4s ease;
}

.culture-card:hover {
    border-left: 3px solid var(--accent);
    background: #0c0c0c;
    transform: translateX(10px);
}

.culture-header {
    margin-bottom: 20px;
}

.culture-tag {
    font-family: var(--font-mono);
    color: var(--accent);
    font-size: 0.7rem;
    display: block;
    margin-bottom: 10px;
    letter-spacing: 2px;
}

.culture-card h4 {
    font-size: 1.2rem;
    text-transform: uppercase;
}

.culture-card p {
    color: var(--text-muted);
    font-size: 0.9rem;
    line-height: 1.6;
}

/* --- Stats Bar Styling --- */
.stats-bar {
    background: #050505;
    border-top: 1px solid var(--border-color);
    border-bottom: 1px solid var(--border-color);
    padding: 40px 0;
}

.stats-wrapper {
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 20px;
}

.stat-item {
    text-align: center;
    flex: 1;
    min-width: 150px;
}

.stat-number {
    display: block;
    font-size: 2.5rem;
    font-weight: 800;
    color: var(--accent);
    font-family: var(--font-mono);
    margin-bottom: 5px;
}

.stat-label {
    font-size: 0.7rem;
    color: var(--text-muted);
    letter-spacing: 2px;
    text-transform: uppercase;
}

/* Vertical dividers for desktop */
.stat-divider {
    width: 1px;
    height: 50px;
    background: #222;
}

@media (max-width: 768px) {
    .stats-wrapper {
        display: grid;
        grid-template-columns: 1fr 1fr;
    }
    .stat-divider {
        display: none;
    }
}

/* --- Universal Glitch Effect --- */
.glitch {
    position: relative;
    display: inline-block;
    color: var(--text-main);
    font-weight: 800;
}

/* The magic happens here: creating the red/blue layers */
.glitch::before,
.glitch::after {
    content: attr(data-text);
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: var(--bg-black); /* Matches your background */
    clip: rect(0, 0, 0, 0); 
}

/* Red Layer */
.glitch:hover::before {
    left: 2px;
    text-shadow: -2px 0 #ff00c1;
    animation: glitch-anim 2s infinite linear alternate-reverse;
}

/* Blue Layer */
.glitch:hover::after {
    left: -2px;
    text-shadow: 2px 0 #00fff9;
    animation: glitch-anim-2 3s infinite linear alternate-reverse;
}

/* Keyframes for the flickering movement */
@keyframes glitch-anim {
    0% { clip: rect(15px, 9999px, 25px, 0); }
    20% { clip: rect(85px, 9999px, 95px, 0); }
    40% { clip: rect(40px, 9999px, 50px, 0); }
    60% { clip: rect(70px, 9999px, 80px, 0); }
    80% { clip: rect(20px, 9999px, 30px, 0); }
    100% { clip: rect(90px, 9999px, 100px, 0); }
}

@keyframes glitch-anim-2 {
    0% { clip: rect(45px, 9999px, 55px, 0); }
    25% { clip: rect(10px, 9999px, 20px, 0); }
    50% { clip: rect(60px, 9999px, 70px, 0); }
    75% { clip: rect(30px, 9999px, 40px, 0); }
    100% { clip: rect(80px, 9999px, 90px, 0); }
}

/* Update the grid for better 6-card display */
.services-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(350px, 1fr));
    gap: 40px; /* Increased gap for 6-card clarity */
    padding: 80px 0;
}

.service-card {
    min-height: 320px; /* Ensures all cards stay aligned */
    display: flex;
    flex-direction: column;
    justify-content: space-between;
}

/* --- Roadmap Styling --- */
.roadmap-section {
    padding: var(--section-padding);
    background: #020202;
}

.roadmap-container {
    position: relative;
    max-width: 900px;
    margin: 0 auto;
}

/* Vertical line connecting steps */
.roadmap-container::before {
    content: '';
    position: absolute;
    left: 20px;
    top: 0;
    width: 2px;
    height: 100%;
    background: linear-gradient(to bottom, var(--accent), #111);
}

.roadmap-step {
    display: flex;
    gap: 40px;
    margin-bottom: 60px;
    position: relative;
}

.step-marker {
    width: 42px;
    height: 42px;
    background: var(--bg-black);
    border: 2px solid var(--accent);
    color: var(--accent);
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: bold;
    font-size: 0.9rem;
    z-index: 2;
    flex-shrink: 0;
}

.step-content h4 {
    color: var(--text-main);
    font-size: 1.2rem;
    margin-bottom: 10px;
}

.step-content p {
    color: var(--text-muted);
    font-size: 0.95rem;
    line-height: 1.7;
}

/* Hover effect to highlight the active path */
.roadmap-step:hover .step-marker {
    background: var(--accent);
    color: #000;
    box-shadow: 0 0 15px var(--accent-glow);
}

@media (max-width: 768px) {
    .roadmap-step { gap: 20px; }
}

/* --- FAQ Styling --- */
.faq-section {
    padding: var(--section-padding);
}

.faq-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(450px, 1fr));
    gap: 40px;
}

.faq-item {
    border-top: 1px solid #111;
    padding-top: 30px;
    transition: 0.3s;
}

.faq-item:hover {
    border-top-color: var(--accent);
}

.faq-question {
    font-size: 1.1rem;
    font-weight: bold;
    margin-bottom: 15px;
    display: flex;
    gap: 10px;
}

.faq-question span {
    color: var(--accent);
}

.faq-answer {
    color: var(--text-muted);
    font-size: 0.95rem;
    line-height: 1.7;
    padding-left: 30px;
}

@media (max-width: 768px) {
    .faq-grid {
        grid-template-columns: 1fr;
    }
}

/* --- Blog Page Specifics --- */
.blog-hero {
    padding: 100px 0 60px;
    position: relative;
    border-bottom: 1px solid var(--border-color);
}

.blog-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(350px, 1fr));
    gap: 40px;
    padding: 80px 0;
}

.blog-card {
    background: #050505;
    border: 1px solid var(--border-color);
    padding: 40px;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    transition: 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
}

.blog-card:hover {
    border-color: var(--accent);
    transform: translateY(-10px);
    box-shadow: 0 10px 30px rgba(0, 255, 65, 0.05);
}

.blog-meta {
    display: flex;
    justify-content: space-between;
    margin-bottom: 20px;
    font-size: 0.75rem;
    font-family: var(--font-mono);
}

.blog-date { color: var(--accent); }
.blog-category { color: #444; }

.blog-title {
    font-size: 1.5rem;
    margin-bottom: 20px;
    line-height: 1.3;
}

.blog-summary {
    color: var(--text-muted);
    font-size: 0.95rem;
    margin-bottom: 30px;
    line-height: 1.6;
}

.read-link {
    text-decoration: none;
    color: var(--text-main);
    font-size: 0.8rem;
    font-weight: bold;
    letter-spacing: 1px;
    transition: 0.3s;
}

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

/* Empty state styling */
.no-posts {
    grid-column: 1 / -1;
    text-align: center;
    padding: 100px 0;
    border: 1px dashed #222;
}

.terminal-msg {
    color: #ff4444;
    margin-bottom: 30px;
    font-family: var(--font-mono);
}

/* --- Blog Post Layout --- */
.post-hero {
    padding: 120px 0 60px;
    border-bottom: 1px solid var(--border-color);
    background: linear-gradient(to bottom, #050505, #000);
}

.post-meta {
    font-family: var(--font-mono);
    font-size: 0.8rem;
    color: #555;
    margin-bottom: 20px;
    letter-spacing: 1px;
}

.narrow-content {
    max-width: 800px; /* Optimal reading width */
    margin: 0 auto;
}

.post-summary-box {
    padding: 30px;
    background: #080808;
    border-left: 3px solid var(--accent);
    margin: 50px 0;
    font-style: italic;
    color: var(--text-main);
}

.article-body {
    line-height: 1.8;
    font-size: 1.1rem;
    color: var(--text-muted);
}

/* Styling for HTML content coming from DB */
.article-body h2, .article-body h3 {
    color: var(--text-main);
    margin: 40px 0 20px;
}

.article-body p { margin-bottom: 25px; }

.article-body code {
    background: #111;
    color: var(--accent);
    padding: 2px 6px;
    font-family: var(--font-mono);
}

/* Post Footer */
.post-internal-footer {
    margin-top: 80px;
    padding-bottom: 60px;
}

.share-block {
    display: flex;
    gap: 20px;
    font-size: 0.8rem;
    font-family: var(--font-mono);
    margin-bottom: 30px;
}

.share-block a {
    color: var(--text-muted);
    text-decoration: none;
}

.share-block a:hover { color: var(--accent); }

.terminal-hr { border: 0; border-top: 1px solid #111; margin: 40px 0; }

.back-btn {
    text-decoration: none;
    color: var(--text-main);
    font-family: var(--font-mono);
    font-weight: bold;
}

/* --- ========================================== --- */
/* ---             ADMIN COMMAND CENTER           --- */
/* --- ========================================== --- */

/* 1. Admin Layout & Dashboard */
.admin-dashboard, .admin-page {
    padding: 60px 0;
    min-height: 80vh;
}

.admin-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-end;
    margin-bottom: 40px;
    border-bottom: 1px solid var(--border-color);
    padding-bottom: 20px;
}

.terminal-info {
    font-family: var(--font-mono);
    font-size: 0.85rem;
    color: var(--text-muted);
    margin-top: 10px;
}

/* 2. Management Table */
.terminal-table-wrapper {
    background: var(--surface);
    border: 1px solid var(--border-color);
    overflow-x: auto;
}

.terminal-table {
    width: 100%;
    border-collapse: collapse;
    font-family: var(--font-mono);
}

.terminal-table th {
    background: #111;
    color: var(--accent);
    text-align: left;
    padding: 15px 20px;
    font-size: 0.8rem;
    text-transform: uppercase;
    letter-spacing: 1px;
}

.terminal-table td {
    padding: 18px 20px;
    border-bottom: 1px solid #111;
    color: var(--text-muted);
    font-size: 0.9rem;
}

.post-title-cell {
    color: var(--text-main) !important;
    font-weight: bold;
}

/* 3. Admin Forms (New & Edit) */
.admin-form-container {
    background: var(--surface);
    border: 1px solid var(--border-color);
    padding: 40px;
    max-width: 900px;
    margin: 0 auto;
}

.admin-form .input-group {
    margin-bottom: 25px;
    display: flex;
    flex-direction: column;
}

.admin-form label {
    font-family: var(--font-mono);
    font-size: 0.75rem;
    color: var(--accent);
    margin-bottom: 10px;
    text-transform: uppercase;
}

.admin-form input, 
.admin-form textarea {
    background: #000;
    border: 1px solid #222;
    padding: 15px;
    color: var(--text-main);
    font-family: var(--font-mono);
    font-size: 1rem;
    transition: 0.3s;
}

.admin-form input:focus, 
.admin-form textarea:focus {
    border-color: var(--accent);
    outline: none;
    box-shadow: 0 0 10px var(--accent-glow);
}

/* 4. Action Buttons & Groups */
.action-group {
    display: flex;
    gap: 12px;
}

.edit-link {
    text-decoration: none;
    color: var(--text-main);
    border: 1px solid #333;
    padding: 6px 14px;
    font-size: 0.75rem;
    transition: 0.3s;
}

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

.delete-btn {
    background: transparent;
    border: 1px solid #ff4444;
    color: #ff4444;
    padding: 6px 14px;
    cursor: pointer;
    font-family: var(--font-mono);
    font-size: 0.75rem;
    transition: 0.3s;
}

.delete-btn:hover {
    background: #ff4444;
    color: #000;
}

.form-actions {
    display: flex;
    gap: 20px;
    margin-top: 30px;
    border-top: 1px solid #222;
    padding-top: 30px;
}

/* 5. Misc Admin UI */
.pulse-dot {
    display: inline-block;
    width: 8px;
    height: 8px;
    background: var(--accent);
    border-radius: 50%;
    margin-right: 5px;
    box-shadow: 0 0 8px var(--accent);
}

.empty-msg {
    text-align: center;
    padding: 50px !important;
    color: #444 !important;
    font-style: italic;
}

.admin-select {
    background: #000;
    border: 1px solid #222;
    padding: 12px;
    color: var(--accent);
    font-family: var(--font-mono);
    text-transform: uppercase;
}

.admin-grid-row { display: grid; grid-template-columns: 1fr 1fr; gap: 20px; margin-bottom: 20px; }

.switch-container { display: flex; align-items: center; cursor: pointer; padding: 15px; background: #111; border: 1px solid #222; }
.switch-container input { width: auto; margin-right: 15px; accent-color: var(--accent); }
.switch-label { font-family: var(--font-mono); font-size: 0.75rem; color: #888; }
input:checked + .switch-label { color: var(--accent); }

/* --- Featured Post Styling --- */

/* The Card Highlight */
.blog-card.featured-protocol {
    border: 1px solid var(--accent); /* Neon Green Border */
    background: linear-gradient(145deg, #0a0a0a, #000);
    box-shadow: 0 0 20px rgba(0, 255, 65, 0.05);
    position: relative;
    transform: scale(1.02); /* Slightly larger than others */
    z-index: 2;
}

/* The Top Label */
.featured-label {
    position: absolute;
    top: -12px;
    left: 20px;
    background: var(--accent);
    color: #000;
    font-family: var(--font-mono);
    font-size: 0.65rem;
    font-weight: bold;
    padding: 2px 10px;
    letter-spacing: 1px;
    display: flex;
    align-items: center;
    gap: 8px;
}

/* Pulsing dot inside the label */
.pulse-icon {
    width: 6px;
    height: 6px;
    background: #000;
    border-radius: 50%;
    animation: pulse-black 1.5s infinite;
}

@keyframes pulse-black {
    0% { transform: scale(0.95); opacity: 0.7; }
    70% { transform: scale(1.2); opacity: 1; }
    100% { transform: scale(0.95); opacity: 0.7; }
}

/* Highlight the title of featured posts */
.featured-protocol .blog-title {
    color: var(--text-main);
    text-shadow: 0 0 5px rgba(255, 255, 255, 0.1);
}

/* --- BLOG CTA / SUBSCRIPTION SECTION --- */

.blog-cta {
    padding: 80px 0;
    background: #050505;
    border-top: 1px solid #111;
}

.cta-inner {
    display: flex;
    justify-content: space-between;
    align-items: center;
    background: #0a0a0a;
    border: 1px solid #1a1a1a;
    padding: 50px;
    gap: 40px;
    position: relative;
    overflow: hidden;
}

/* Decorative background text */
.cta-inner::after {
    content: "CONNECTED_SYSTEM";
    position: absolute;
    right: -20px;
    bottom: -10px;
    font-family: var(--font-mono);
    font-size: 5rem;
    font-weight: 900;
    color: rgba(255, 255, 255, 0.02);
    pointer-events: none;
    z-index: 0;
}

.cta-text {
    flex: 1;
    z-index: 1;
}

.cta-text h3 {
    font-size: 1.8rem;
    color: var(--text-main);
    margin-bottom: 15px;
    font-family: var(--font-mono);
}

.cta-text p {
    color: var(--text-muted);
    font-size: 1rem;
    max-width: 500px;
}

/* Mini Form Styling */
.mini-form {
    flex: 1;
    display: flex;
    gap: 15px;
    z-index: 1;
}

.mini-form input {
    flex: 1;
    background: #000;
    border: 1px solid #222;
    padding: 15px 20px;
    color: var(--text-main);
    font-family: var(--font-mono);
    font-size: 0.9rem;
    transition: 0.3s ease;
}

.mini-form input:focus {
    border-color: var(--accent);
    outline: none;
}

.mini-form .btn-primary {
    padding: 0 35px;
    white-space: nowrap;
}

/* RESPONSIVE FIXES */
@media (max-width: 992px) {
    .cta-inner {
        flex-direction: column;
        text-align: center;
        padding: 40px 20px;
    }
    
    .cta-text p {
        margin: 0 auto;
    }

    .mini-form {
        width: 100%;
        flex-direction: column;
    }
    
    .mini-form .btn-primary {
        padding: 15px;
    }
}

.admin-stats { margin-bottom: 30px; }
.stat-card {
    background: #0a0a0a;
    border: 1px solid var(--accent);
    padding: 20px;
    display: inline-block;
    min-width: 200px;
}
.stat-card .label { display: block; font-size: 0.7rem; color: #555; font-family: var(--font-mono); }
.stat-card .value { font-size: 2rem; color: var(--accent); font-weight: bold; }

.nav-item.active {
    color: var(--accent); /* Neon Green */
    border-bottom: 1px solid var(--accent);
}

