/* Hitech Theme - Aliciê 3D - Dark Mode Refined */

:root {
    --primary-color: #E01040;
    /* Laser Burgundy */
    --primary-dim: #600515;
    --accent-color: #FF2A68;
    /* Neon Red/Pink */
    --accent-glow: rgba(255, 42, 104, 0.6);

    --text-white: #FFFFFF;
    --text-gray: #B0B0B0;

    --bg-deep: #000000;
    --bg-panel: #0A0A0A;
    --bg-card: #111111;

    --border-color: #333333;
    --grid-line: rgba(255, 255, 255, 0.03);

    --font-heading: 'Rajdhani', sans-serif;
    --font-mono: 'Share Tech Mono', monospace;

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

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

body {
    font-family: var(--font-heading);
    background-color: var(--bg-deep);
    color: var(--text-white);
    overflow-x: hidden;
    position: relative;
    font-weight: 500;
}

/* Background Canvas */
#tech-bg {
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    z-index: -1;
    opacity: 0.6;
    pointer-events: none;
}

/* Typography */
h1,
h2,
h3,
h4 {
    font-family: var(--font-heading);
    text-transform: uppercase;
    font-weight: 700;
    letter-spacing: 2px;
    color: var(--text-white);
}

.mono-text {
    font-family: var(--font-mono);
    font-size: 0.95rem;
    color: var(--text-gray);
    letter-spacing: 0.5px;
}

.hollow-text {
    color: transparent;
    -webkit-text-stroke: 1px var(--primary-color);
    text-shadow: 0 0 10px rgba(224, 16, 64, 0.3);
}

/* --- Navigation --- */
.navbar {
    position: fixed;
    width: 100%;
    padding: 20px 0;
    z-index: 1000;
    background: rgba(0, 0, 0, 0.85);
    /* Darker blur */
    backdrop-filter: blur(12px);
    border-bottom: 1px solid rgba(255, 42, 104, 0.2);
}

.logo {
    font-size: 2rem;
    font-weight: 700;
    color: var(--text-white);
    text-shadow: 0 0 15px var(--primary-color);
    position: absolute;
    top: -8px;
}

.logo .dot {
    color: var(--accent-color);
    text-shadow: 0 0 10px var(--accent-color);
}

.nav-links {
    display: flex;
    gap: 40px;
    list-style: none;
    padding-top: 5px;
    text-align: right;
    float: inline-end;
}

.nav-links a {
    font-family: var(--font-mono);
    font-size: 1rem;
    color: var(--text-gray);
    text-decoration: none;
    position: relative;
    transition: color 0.3s;
}

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

.nav-links a::after {
    content: '';
    position: absolute;
    width: 0;
    height: 2px;
    bottom: -5px;
    left: 0;
    background-color: var(--accent-color);
    box-shadow: 0 0 8px var(--accent-color);
    transition: var(--transition);
}

.nav-links a:hover::after {
    width: 100%;
}

/* --- Hero Section --- */
.hero {
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    /* Center horizontally */
    position: relative;
    padding-top: 80px;
    overflow: hidden;
    text-align: center;
    /* Center text */
}

.hero-content {
    max-width: 900px;
    z-index: 2;
    padding: 0 20px;
    display: flex;
    flex-direction: column;
    align-items: center;
    /* Center flex items */
}

.tech-badge {
    display: inline-block;
    padding: 6px 14px;
    border: 1px solid var(--accent-color);
    color: var(--accent-color);
    font-family: var(--font-mono);
    font-size: 0.85rem;
    margin-bottom: 25px;
    background: rgba(255, 42, 104, 0.08);
    box-shadow: 0 0 15px rgba(255, 42, 104, 0.15);
}

.hero h1 {
    font-size: 4.5rem;
    line-height: 1.1;
    margin-bottom: 25px;
}

.hero-description {
    font-family: var(--font-mono);
    font-size: 1.25rem;
    color: var(--text-gray);
    margin-bottom: 40px;
    /* Changed style for centered layout */
    border-left: none;
    border-bottom: 2px solid var(--primary-color);
    padding-bottom: 15px;
    padding-left: 0;
    background: linear-gradient(180deg, rgba(224, 16, 64, 0.1) 0%, transparent 100%);
    max-width: 700px;
    /* Limit width for readability */
}

.hero-btns {
    display: flex;
    gap: 20px;
    justify-content: center;
    /* Center buttons */
    flex-wrap: wrap;
}

/* Buttons */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 16px 45px;
    font-family: var(--font-heading);
    text-transform: uppercase;
    font-weight: 700;
    text-decoration: none;
    transition: var(--transition);
    letter-spacing: 1.5px;
    font-size: 0.9rem;
    position: relative;
    clip-path: polygon(15px 0, 100% 0, 100% calc(100% - 15px), calc(100% - 15px) 100%, 0 100%, 0 15px);
}

.btn-primary {
    background-color: var(--primary-color);
    color: white;
    box-shadow: 0 0 20px rgba(224, 16, 64, 0.4);
}

.btn-primary:hover {
    background-color: var(--accent-color);
    box-shadow: 0 0 35px rgba(255, 42, 104, 0.6);
    transform: translateY(-2px);
}

.btn-outline {
    background: transparent;
    color: var(--primary-color);
    border: 1px solid var(--primary-color);
    box-shadow: inset 0 0 10px rgba(224, 16, 64, 0.1);
}

.btn-outline:hover {
    background: rgba(224, 16, 64, 0.1);
    color: var(--accent-color);
    border-color: var(--accent-color);
    box-shadow: 0 0 20px rgba(224, 16, 64, 0.3);
}

/* Stats */
.hero-stats {
    position: absolute;
    right: 5%;
    bottom: 10%;
    display: flex;
    flex-direction: column;
    gap: 20px;
    z-index: 2;
}

.stat-box {
    background: rgba(15, 15, 15, 0.9);
    padding: 15px 25px;
    border-right: 3px solid var(--accent-color);
    backdrop-filter: blur(5px);
    border-radius: 4px;
    text-align: right;
    box-shadow: -5px 5px 15px rgba(0, 0, 0, 0.5);
}

.stat-box .label {
    display: block;
    font-size: 0.75rem;
    color: var(--text-gray);
    margin-bottom: 5px;
}

.stat-box .value {
    font-size: 1.6rem;
    font-weight: 700;
    color: var(--text-white);
    font-family: var(--font-mono);
}

/* --- Sections Layout --- */
.section {
    padding: 120px 0;
    position: relative;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 30px;
    position: relative;
    z-index: 2;
}

.section-title {
    font-size: 3rem;
    margin-bottom: 60px;
    position: relative;
    text-shadow: 0 0 20px rgba(0, 0, 0, 0.8);
}

.section-title::before {
    content: '';
    position: absolute;
    bottom: -15px;
    left: 0;
    width: 80px;
    height: 4px;
    background: var(--accent-color);
    box-shadow: 0 0 15px var(--accent-color);
}

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

.text-center .section-title::before {
    left: 50%;
    transform: translateX(-50%);
}

.row {
    display: flex;
    flex-wrap: wrap;
    gap: 50px;
    align-items: center;
}

.col-text,
.col-image {
    flex: 1;
    min-width: 320px;
}

/* About Block */
.code-block {
    background: var(--bg-card);
    padding: 40px;
    border: 1px solid var(--border-color);
    position: relative;
    line-height: 30px;
}

/* Decorative corner for code block */
.code-block::after {
    content: '';
    position: absolute;
    top: -1px;
    right: -1px;
    width: 30px;
    height: 30px;
    border-top: 2px solid var(--accent-color);
    border-right: 2px solid var(--accent-color);
}

.tech-frame {
    height: 450px;
    background: #080808;
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
    overflow: hidden;
    border: 1px solid var(--border-color);
    box-shadow: 0 0 30px rgba(0, 0, 0, 0.5);
}

.tech-frame i {
    font-size: 6rem;
    color: var(--primary-color);
    z-index: 2;
    filter: drop-shadow(0 0 20px var(--primary-color));
}

.scan-lines {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: repeating-linear-gradient(0deg,
            rgba(255, 255, 255, 0.02),
            rgba(255, 255, 255, 0.02) 1px,
            transparent 1px,
            transparent 3px);
    z-index: 1;
    pointer-events: none;
}

/* --- Services: Grid Layout Fixes --- */
.services-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
    gap: 30px;
    perspective: 1000px;
}

.service-card {
    background: var(--bg-card);
    padding: 40px 30px;
    border: 1px solid var(--border-color);
    position: relative;
    transition: var(--transition);
    height: 100%;
    /* Equal height */
    overflow: hidden;
}

.service-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 2px;
    height: 0;
    background: var(--accent-color);
    transition: 0.5s ease;
}

.service-card:hover::before {
    height: 100%;
}

.service-card:hover {
    transform: translateY(-10px);
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.5);
    background: #151515;
}

.icon-box {
    margin-bottom: 25px;
    color: var(--primary-color);
    font-size: 3rem;
    filter: drop-shadow(0 0 10px rgba(224, 16, 64, 0.3));
}

.tech-border::after {
    content: '';
    position: absolute;
    top: 0;
    right: 0;
    border-top: 30px solid var(--primary-dim);
    border-left: 30px solid transparent;
    transition: var(--transition);
}

.service-card:hover .tech-border::after {
    border-top-color: var(--accent-color);
}

/* --- Tech Specs Section --- */
.dark-bg {
    background-color: #050505;
    /* Distinction */
    border-top: 1px solid var(--border-color);
    border-bottom: 1px solid var(--border-color);
}

.tech-grid-overlay {
    position: absolute;
    top: 0;
    left: 0;
    bottom: 0;
    right: 0;
    background-image:
        linear-gradient(rgba(255, 255, 255, 0.02) 1px, transparent 1px),
        linear-gradient(90deg, rgba(255, 255, 255, 0.02) 1px, transparent 1px);
    background-size: 40px 40px;
    pointer-events: none;
}

.features-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 40px;
    text-align: center;
}

.feature-item {
    padding: 20px;
}

.feature-item .number {
    font-size: 6rem;
    line-height: 1;
    font-weight: 700;
    color: transparent;
    -webkit-text-stroke: 1px rgba(255, 42, 104, 0.5);
    /* Accent stroke */
    display: block;
    margin-bottom: 5px;
    font-family: var(--font-heading);
    opacity: 0.8;
}

.feature-item h4 {
    color: var(--accent-color);
    margin-bottom: 10px;
    font-size: 1.2rem;
}

/* --- Contact Form Fix --- */
.contact-form {
    margin-top: 40px;
}

.tech-form {
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    padding: 0;
}

.form-header {
    background: #1a1a1a;
    padding: 15px 30px;
    border-bottom: 1px solid var(--primary-dim);
    display: flex;
    justify-content: space-between;
    font-family: var(--font-mono);
    color: var(--text-gray);
    font-size: 0.9rem;
}

.tech-form .form-group {
    padding: 0 30px;
    margin-top: 25px;
}

.tech-form label {
    color: var(--primary-color);
    font-size: 0.8rem;
    margin-bottom: 8px;
    display: block;
}

.tech-form input,
.tech-form textarea {
    width: 100%;
    background: #080808;
    border: 1px solid #333;
    color: var(--text-white);
    padding: 12px;
    font-family: var(--font-mono);
    transition: var(--transition);
}

.tech-form input:focus,
.tech-form textarea:focus {
    border-color: var(--accent-color);
    outline: none;
    box-shadow: 0 0 15px rgba(255, 42, 104, 0.1);
}

.tech-form button {
    width: 100%;
    margin-top: 30px;
    border: none;
    background: var(--primary-color);
    padding: 15px;
    color: white;
    font-family: var(--font-heading);
    font-weight: 700;
    text-transform: uppercase;
    cursor: pointer;
    transition: var(--transition);
}

.tech-form button:hover {
    background: var(--accent-color);
}

.social-links a {
    color: var(--text-white);
    font-size: 1.5rem;
    margin: 0 15px;
    transition: color 0.3s;
}

.social-links a:hover {
    color: var(--accent-color);
}

/* --- Footer --- */
footer {
    padding: 40px 0;
    text-align: center;
    border-top: 1px solid #222;
    background: #020202;
    color: #555;
    font-size: 0.9rem;
}

/* --- PRINTER EFFECT (RESTORED & ENHANCED) --- */
.printer-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100vh;
    z-index: 9999;
    pointer-events: none;
}

/* The Horizontal Laser Beam Bar */
.print-head {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 2px;
    background: #FF2A68;
    /* Core white/pink hot center */
    box-shadow:
        0 0 10px #FF2A68,
        0 0 20px #FF2A68,
        0 -20px 40px rgba(255, 42, 104, 0.5);
    /* Glow upwards */
    z-index: 10000;
}

.print-beam {
    /* Optional: A vertical light sheet if desired, but bar is better for "scan" */
}

/* The Mechanical Nozzle Head moving L/R */
.nozzle {
    width: 40px;
    height: 25px;
    background: linear-gradient(to bottom, #333, #111);
    border: 1px solid #555;
    border-bottom: 2px solid #FF2A68;
    /* Hot tip */
    position: absolute;
    top: -25px;
    /* Sit on top of the beam */
    left: 50%;
    transform: translateX(-50%);
    box-shadow: 0 0 15px rgba(255, 42, 104, 0.3);
}

.temp-readout {
    position: absolute;
    right: 30px;
    bottom: 10px;
    /* Below the line */
    color: #FF2A68;
    background: rgba(0, 0, 0, 0.9);
    padding: 4px 8px;
    border: 1px solid #FF2A68;
    font-family: 'Share Tech Mono', monospace;
    font-size: 0.8rem;
    box-shadow: 0 0 10px rgba(255, 42, 104, 0.2);
}

/* --- Visibility Logic --- */
.hidden-initially {
    opacity: 0;
    transform: translateY(30px);
    transition: opacity 0.6s ease-out, transform 0.6s ease-out;
}

.revealed {
    opacity: 1;
    transform: translateY(0);
}

/* --- Mobile Nav Fix --- */
.menu-toggle {
    display: none;
    z-index: 1001;
    /* Ensure it's above everything */
}

.close-menu {
    display: none;
    position: absolute;
    top: 20px;
    right: 30px;
    font-size: 2rem;
    color: var(--accent-color);
    cursor: pointer;
}

@media (max-width: 900px) {
    .navbar .container {
        display: flex;
        justify-content: space-between;
        align-items: center;
    }

    .hero {
        text-align: center;
        justify-content: center;
        padding-top: 100px;
    }

    .hero-content {
        padding: 0 20px;
        max-width: 100%;
        display: flex;
        flex-direction: column;
        align-items: center;
    }

    .hero-description {
        border-left: none;
        /* Remove side border for centered look */
        border-bottom: 2px solid var(--primary-color);
        /* Add bottom border instead */
        padding-left: 0;
        padding-bottom: 15px;
        margin-bottom: 30px;
        background: linear-gradient(180deg, rgba(224, 16, 64, 0.1) 0%, transparent 100%);
    }

    .hero h1 {
        font-size: 2rem;
        /* Smaller for mobile to prevent cut off */
        word-wrap: break-word;
        /* Ensure wrapping */
    }
    .stat-box{
        padding: 5px 10px;
    }
    .hero-stats {
        right: 0%;
        bottom: 1%;
    }

    .hero-btns {
        justify-content: center;
        width: 100%;
    }

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

    .menu-toggle {
        display: block;
        font-size: 1.8rem;
        color: white;
        cursor: pointer;
        position: static;
        /* Removed absolute position to flow naturally with flex */
        margin-left: auto;
        /* Push to right if needed in flex container */
    }

    .nav-links {
        position: fixed;
        top: 0;
        left: 0;
        width: 100%;
        height: 100vh;
        background: rgba(0, 0, 0, 0.98);
        /* Less transparent for focus */
        flex-direction: column;
        justify-content: center;
        align-items: center;
        padding: 0;
        transform: translateX(100%);
        transition: transform 0.4s cubic-bezier(0.77, 0, 0.175, 1);
        z-index: 1001;
        /* Above almost everything */
    }

    .nav-links.active {
        transform: translateX(0);
    }

    .close-menu {
        display: block;
        /* Show X only on mobile inside menu */
    }

    .nav-links a {
        font-size: 2rem;
        margin: 5px 0;
        display: block;
    }
}

/* --- Cases / Gallery --- */
.cases-gallery {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    /* 4 columns for dense grid */
    gap: 15px;
    grid-auto-rows: 250px;
}

.case-item {
    position: relative;
    overflow: hidden;
    cursor: pointer;
    border: 1px solid var(--border-color);
}

/* Make first item span 2x2 */
.case-item.large {
    grid-column: span 2;
    grid-row: span 2;
}

.case-img {
    width: 100%;
    height: 100%;
    background-size: cover;
    background-position: center;
    transition: transform 0.5s ease;
    filter: grayscale(80%) contrast(120%);
}

.case-item:hover .case-img {
    transform: scale(1.1);
    filter: grayscale(0%) contrast(100%);
}

.case-overlay {
    position: absolute;
    bottom: 0;
    left: 0;
    width: 100%;
    padding: 20px;
    background: linear-gradient(to top, rgba(0, 0, 0, 0.9), transparent);
    transform: translateY(100%);
    transition: transform 0.3s ease;
}

.case-item:hover .case-overlay {
    transform: translateY(0);
}

.case-overlay h3 {
    font-size: 1.1rem;
    color: var(--accent-color);
    margin-bottom: 5px;
    text-shadow: 0 0 5px rgba(0, 0, 0, 0.8);
}

.case-overlay p {
    font-family: var(--font-mono);
    font-size: 0.8rem;
    color: var(--text-white);
}

/* Tablet / Mobile Grid Adjustments */
@media (max-width: 900px) {
    .cases-gallery {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 600px) {
    .cases-gallery {
        grid-template-columns: 1fr;
        grid-auto-rows: 300px;
    }

    .case-item.large {
        grid-column: span 1;
        grid-row: span 1;
    }
}