:root {
    /* Base Colors - Inspired by Logo Dark Metal & Neon */
    --main-bg: #050505;
    /* Deep Black */
    --secondary-bg: #111116;
    /* Dark Metallic Gunmetal */
    --card-bg: rgba(20, 20, 25, 0.95);

    /* Accents */
    --primary-orange: #ff9f1c;
    /* Bright Orange */
    --primary-red: #ff4500;
    /* Deep Red-Orange */
    --neon-glow: rgba(255, 69, 0, 0.5);

    /* Text */
    --text-main: #ffffff;
    --text-muted: #8b9bb4;

    /* Borders */
    --border-color: #2a2a35;

    /* Fonts */
    --font-main: 'Roboto', sans-serif;
    --font-heading: 'Orbitron', sans-serif;
}

* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

body {
    background-color: var(--main-bg);
    color: var(--text-main);
    font-family: var(--font-main);
    line-height: 1.6;
    display: flex;
    flex-direction: column;
    min-height: 100vh;
    background-image:
        radial-gradient(circle at 15% 15%, rgba(255, 69, 0, 0.08) 0%, transparent 25%),
        radial-gradient(circle at 85% 85%, rgba(255, 159, 28, 0.05) 0%, transparent 25%);
}

h1,
h2,
h3 {
    font-family: var(--font-heading);
    color: var(--text-main);
    margin-bottom: 1rem;
    text-transform: uppercase;
    letter-spacing: 2px;
}

h1 {
    font-size: 2.8rem;
    background: linear-gradient(to right, #ff9f1c, #ff4500);
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
    text-shadow: 0 0 20px rgba(255, 69, 0, 0.3);
}

a {
    color: var(--primary-orange);
    text-decoration: none;
    transition: all 0.3s ease;
}

a:hover {
    color: #fff;
    text-shadow: 0 0 8px var(--primary-orange);
}

/* Header */
/* Header */
header {
    background-color: rgba(5, 5, 5, 0.9);
    padding: 0.2rem 0;
    /* Reduced from 1rem */
    border-bottom: 1px solid var(--border-color);
    position: sticky;
    top: 0;
    z-index: 1000;
    backdrop-filter: blur(10px);
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.5);
}

nav {
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    max-width: 1400px;
    margin: 0 auto;
    padding: 0 20px;
    gap: 5px;
    /* Reduced from 15px */
    /* Space between logo and menu */
}

.brand-logo {
    height: 250px;
    filter: drop-shadow(0 0 5px rgba(255, 69, 0, 0.4));
    transition: filter 0.3s;
}

.brand-logo:hover {
    filter: drop-shadow(0 0 10px rgba(255, 69, 0, 0.8));
}

.nav-links {
    list-style: none;
    display: flex;
    gap: 40px;
    padding-top: 5px;
    /* Reduced from 10px */
    border-top: 1px solid rgba(255, 255, 255, 0.05);
    /* Subtle separator */
    width: 100%;
    justify-content: center;
}

.nav-links a {
    color: #e0e0e0;
    font-weight: 400;
    font-size: 0.95rem;
    letter-spacing: 1px;
    font-family: var(--font-heading);
    text-transform: uppercase;
    position: relative;
    padding: 5px 0;
}

.nav-links a::after {
    content: '';
    position: absolute;
    width: 0;
    height: 2px;
    bottom: 0;
    left: 0;
    background: linear-gradient(90deg, var(--primary-orange), var(--primary-red));
    transition: width 0.3s;
}

.nav-links a:hover {
    color: #fff;
}

.nav-links a:hover::after {
    width: 100%;
}

/* Main Content */
main {
    flex: 1;
    max-width: 1400px;
    margin: 4rem auto;
    padding: 0 40px;
    width: 100%;
}

/* Hero Section */
.hero-section {
    padding: 6rem 0;
    text-align: center;
    border-bottom: 1px solid var(--border-color);
    margin-bottom: 4rem;
    position: relative;
}

.hero-section::after {
    content: '';
    position: absolute;
    bottom: -1px;
    left: 50%;
    transform: translateX(-50%);
    width: 200px;
    height: 3px;
    background: linear-gradient(90deg, transparent, var(--primary-red), transparent);
}

.hero-section p {
    font-size: 1.4rem;
    color: var(--text-muted);
    max-width: 700px;
    margin: 0 auto 3rem;
    font-weight: 300;
}

/* Tech Card Style */
.card {
    background-color: var(--card-bg);
    padding: 35px;
    border: 1px solid var(--border-color);
    clip-path: polygon(0 0, 100% 0, 100% calc(100% - 20px), calc(100% - 20px) 100%, 0 100%, 0 10px);
    margin-bottom: 2rem;
    position: relative;
    transition: all 0.3s ease;
}

.card:hover {
    transform: translateY(-5px);
    border-color: var(--primary-red);
    box-shadow: 0 0 20px rgba(255, 69, 0, 0.1);
}

.card h2,
.card h3 {
    color: #fff;
    border-left: 3px solid var(--primary-orange);
    padding-left: 15px;
}

/* Tech Button */
.btn {
    display: inline-block;
    background: transparent;
    color: var(--primary-orange);
    padding: 12px 30px;
    border: 1px solid var(--primary-orange);
    font-family: var(--font-heading);
    font-weight: bold;
    text-transform: uppercase;
    letter-spacing: 2px;
    cursor: pointer;
    transition: all 0.3s;
    position: relative;
    overflow: hidden;
    clip-path: polygon(10px 0, 100% 0, 100% calc(100% - 10px), calc(100% - 10px) 100%, 0 100%, 0 10px);
}

.btn:hover {
    background: var(--primary-orange);
    color: #000;
    box-shadow: 0 0 20px var(--neon-glow);
}

/* Forms */
.form-group {
    margin-bottom: 2rem;
}

label {
    display: block;
    margin-bottom: 0.8rem;
    color: var(--text-muted);
    font-family: var(--font-heading);
    font-size: 0.85rem;
    letter-spacing: 1px;
}

input,
textarea,
select {
    width: 100%;
    padding: 15px;
    background-color: #0a0a0e;
    border: 1px solid var(--border-color);
    color: #fff;
    font-family: var(--font-main);
    transition: all 0.3s;
    border-radius: 0;
}

input:focus,
textarea:focus {
    outline: none;
    border-color: var(--primary-orange);
    box-shadow: 0 0 10px rgba(255, 159, 28, 0.1);
}

/* Footer */
footer {
    background-color: #08080a;
    text-align: center;
    padding: 3rem 0;
    margin-top: auto;
    color: var(--text-muted);
    border-top: 1px solid var(--border-color);
    font-size: 0.9rem;
}

/* Carousel Styling */
.carousel-container {
    position: relative;
    max-width: 100%;
    margin: 0 auto;
    padding: 0 80px;
    /* More space for buttons */
}

.carousel-wrapper {
    overflow: hidden;
    width: 100%;
}

.carousel-track {
    display: flex;
    transition: transform 0.4s ease-in-out;
    gap: 32px;
    /* 2rem gap */
    padding: 10px 0;
    /* Space for shadow */
}

.carousel-card {
    /* Show 3 items: 100% / 3 minus gap adjustment */
    flex: 0 0 calc(33.333% - 22px);
    min-width: 300px;
    /* Min width for responsiveness */
    margin-bottom: 0;
    /* Override default card margin */
    height: auto;
}

.carousel-btn {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    width: 50px;
    height: 50px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: rgba(0, 0, 0, 0.8);
    color: var(--primary-orange);
    border: 2px solid var(--primary-orange);
    font-size: 1.5rem;
    cursor: pointer;
    z-index: 10;
    clip-path: polygon(10px 0, 100% 0, 100% calc(100% - 10px), calc(100% - 10px) 100%, 0 100%, 0 10px);
    transition: all 0.3s;
}

.carousel-btn:hover {
    background: var(--primary-orange);
    color: black;
    box-shadow: 0 0 20px var(--neon-glow);
    transform: translateY(-50%) scale(1.1);
}

.prev-btn {
    left: 0;
}

.next-btn {
    right: 0;
}

@media (max-width: 1024px) {
    .carousel-card {
        flex: 0 0 calc(50% - 16px);
        /* 2 items */
    }
}

@media (max-width: 768px) {
    .carousel-card {
        flex: 0 0 100%;
        /* 1 item */
    }
}


/* Grid for Projects */
.project-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(350px, 1fr));
    gap: 3rem;
}

.project-card {
    height: 100%;
    display: flex;
    flex-direction: column;
}

.project-card img {
    width: 100%;
    height: 240px;
    object-fit: contain;
    background-color: #0b0c10;
    border: 1px solid var(--border-color);
    margin-bottom: 1.5rem;
    padding: 10px;
}

.project-card .category-tag {
    display: inline-block;
    color: var(--primary-orange);
    border: 1px solid var(--primary-orange);
    padding: 2px 8px;
    font-size: 0.75rem;
    margin-bottom: 1rem;
    font-weight: bold;
    text-transform: uppercase;
    letter-spacing: 1px;
    font-family: var(--font-heading);
    align-self: flex-start;
}

.project-card p {
    flex: 0 0 auto;
    height: 250px;
    /* Increased height for ~12 lines */
    overflow: hidden;
    color: var(--text-muted);
    font-size: 1rem;
    font-weight: 300;
    margin-bottom: 1rem;
    position: relative;
    /* Basic line clamp fallback */
    display: -webkit-box;
    -webkit-line-clamp: 12;
    line-clamp: 12;
    /* Standard property */
    -webkit-box-orient: vertical;
}

.read-more-link {
    color: var(--primary-orange);
    text-decoration: underline;
    cursor: pointer;
    font-size: 0.9rem;
    margin-bottom: 1rem;
    display: none;
    /* Hidden by default, shown by JS if needed */
}

/* Modal Styling */
.modal {
    display: none;
    position: fixed;
    z-index: 2000;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    overflow: auto;
    background-color: rgba(0, 0, 0, 0.9);
    backdrop-filter: blur(5px);
}

.modal-content {
    background-color: var(--secondary-bg);
    margin: 5% auto;
    padding: 30px;
    border: 1px solid var(--primary-orange);
    width: 80%;
    max-width: 800px;
    border-radius: 8px;
    position: relative;
    box-shadow: 0 0 30px rgba(255, 159, 28, 0.3);
}

.close-modal {
    position: absolute;
    top: 15px;
    right: 20px;
    color: var(--text-muted);
    font-size: 28px;
    font-weight: bold;
    cursor: pointer;
}

.close-modal:hover {
    color: var(--primary-orange);
}

/* Filter Buttons */
.filter-btn {
    background: transparent;
    border: 1px solid var(--border-color);
    color: var(--text-muted);
    padding: 8px 20px;
    margin: 0 5px;
    border-radius: 20px;
    cursor: pointer;
    font-family: var(--font-heading);
    text-transform: uppercase;
    transition: all 0.3s;
}

.filter-btn:hover,
.filter-btn.active {
    background: var(--primary-orange);
    color: #000;
    color: #000;
    border-color: var(--primary-orange);
    box-shadow: 0 0 10px rgba(255, 159, 28, 0.4);
}

/* Intro Overlay */
#intro-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100vh;
    background-color: #000;
    z-index: 9999;
    display: flex;
    justify-content: center;
    align-items: center;
    transition: opacity 0.8s ease-out, visibility 0.8s;
}

#intro-video {
    width: 100%;
    height: 100%;
    object-fit: contain;
    /* Adjust to 'cover' if you want it to fill the screen completely */
}

/* Hide scrollbar when intro is active (handled via JS class usually, but basic overlay works) */
body.intro-active {
    overflow: hidden;
}