:root {
    --bg: #050505;
    --surface: #121214;
    --accent: #ff3e3e;
    --accent-blue: #00e5ff;
    --accent-yellow: #ffd600;
    --text-main: #ffffff;
    --text-dim: #a0a0a8;
    --nav-height: 80px;
    --transition: all 0.4s cubic-bezier(0.16, 1, 0.3, 1);
}

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

html {
    scroll-behavior: smooth;
}

body {
    background-color: var(--bg);
    color: var(--text-main);
    font-family: 'Outfit', sans-serif;
    overflow-x: hidden;
    line-height: 1.6;
}

.accent { color: var(--accent); }
.text-center { text-align: center; }

/* Navbar */
.navbar {
    position: fixed;
    top: 0;
    width: 100%;
    height: var(--nav-height);
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 0 10%;
    background: rgba(5, 5, 5, 0.8);
    backdrop-filter: blur(10px);
    z-index: 1000;
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
}

.logo {
    font-family: 'Bungee', cursive;
    font-size: 1.8rem;
    letter-spacing: 2px;
}

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

.nav-links a {
    color: var(--text-main);
    text-decoration: none;
    font-size: 0.95rem;
    font-weight: 400;
    text-transform: uppercase;
    letter-spacing: 1px;
    transition: var(--transition);
}

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

/* Hero Section */
.hero {
    position: relative;
    height: 100vh;
    display: flex;
    justify-content: center;
    align-items: center;
    text-align: center;
    overflow: hidden;
}

.parallax-bg {
    position: absolute;
    top: -10%;
    left: -10%;
    width: 120%;
    height: 120%;
    background: url('hero.png') center/cover no-repeat;
    z-index: -1;
    filter: brightness(0.4);
    will-change: transform;
}

.hero-content {
    max-width: 900px;
    padding: 0 2rem;
    z-index: 10;
}

.glitch-text {
    font-family: 'Bungee', cursive;
    font-size: clamp(3rem, 10vw, 6rem);
    line-height: 1;
    margin-bottom: 1.5rem;
    position: relative;
    text-shadow: 0.05em 0 0 rgba(255, 0, 0, 0.75),
                -0.025em -0.05em 0 rgba(0, 255, 0, 0.75),
                0.025em 0.05em 0 rgba(0, 0, 255, 0.75);
    animation: glitch 500ms infinite;
}

@keyframes glitch {
    0% { text-shadow: 0.05em 0 0 rgba(255, 0, 0, 0.75), -0.05em -0.025em 0 rgba(0, 255, 0, 0.75), -0.025em 0.05em 0 rgba(0, 0, 255, 0.75); }
    14% { text-shadow: 0.05em 0 0 rgba(255, 0, 0, 0.75), -0.05em -0.025em 0 rgba(0, 255, 0, 0.75), -0.025em 0.05em 0 rgba(0, 0, 255, 0.75); }
    15% { text-shadow: -0.05em -0.025em 0 rgba(255, 0, 0, 0.75), 0.025em 0.025em 0 rgba(0, 255, 0, 0.75), -0.05em -0.05em 0 rgba(0, 0, 255, 0.75); }
    49% { text-shadow: -0.05em -0.025em 0 rgba(255, 0, 0, 0.75), 0.025em 0.025em 0 rgba(0, 255, 0, 0.75), -0.05em -0.05em 0 rgba(0, 0, 255, 0.75); }
    50% { text-shadow: 0.025em 0.05em 0 rgba(255, 0, 0, 0.75), 0.05em 0 0 rgba(0, 255, 0, 0.75), 0 -0.05em 0 rgba(0, 0, 255, 0.75); }
    99% { text-shadow: 0.025em 0.05em 0 rgba(255, 0, 0, 0.75), 0.05em 0 0 rgba(0, 255, 0, 0.75), 0 -0.05em 0 rgba(0, 0, 255, 0.75); }
    100% { text-shadow: -0.025em 0 0 rgba(255, 0, 0, 0.75), -0.025em -0.025em 0 rgba(0, 255, 0, 0.75), -0.025em -0.05em 0 rgba(0, 0, 255, 0.75); }
}

.hero p {
    font-size: 1.4rem;
    color: var(--text-dim);
    margin-bottom: 2.5rem;
}

.hero-btns {
    display: flex;
    justify-content: center;
    gap: 1.5rem;
}

.btn {
    padding: 1rem 2.5rem;
    border-radius: 100px;
    font-size: 1rem;
    font-weight: 700;
    text-transform: uppercase;
    text-decoration: none;
    transition: var(--transition);
    cursor: pointer;
    border: none;
}

.btn.primary {
    background: var(--accent);
    color: white;
    box-shadow: 0 10px 20px rgba(255, 62, 62, 0.3);
}

.btn.primary:hover {
    transform: translateY(-5px);
    box-shadow: 0 15px 30px rgba(255, 62, 62, 0.5);
}

.btn.secondary {
    background: transparent;
    border: 2px solid white;
    color: white;
}

.btn.secondary:hover {
    background: white;
    color: var(--bg);
}

/* Portfolio Grid */
.portfolio {
    padding: 100px 10%;
}

.section-header {
    margin-bottom: 4rem;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 2rem;
}

.title {
    font-family: 'Bungee', cursive;
    font-size: 3rem;
}

.filters {
    display: flex;
    gap: 1rem;
    flex-wrap: wrap;
    justify-content: center;
}

.filter-btn {
    padding: 0.6rem 1.5rem;
    background: var(--surface);
    border: 1px solid rgba(255, 255, 255, 0.1);
    color: var(--text-dim);
    border-radius: 100px;
    cursor: pointer;
    transition: var(--transition);
}

.filter-btn.active, .filter-btn:hover {
    background: var(--accent);
    color: white;
    border-color: var(--accent);
}

.portfolio-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(350px, 1fr));
    gap: 2rem;
}

.portfolio-item {
    position: relative;
    border-radius: 20px;
    overflow: hidden;
    height: 450px;
    cursor: pointer;
}

.portfolio-item img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.6s cubic-bezier(0.16, 1, 0.3, 1);
}

.item-overlay {
    position: absolute;
    inset: 0;
    background: linear-gradient(to top, rgba(0,0,0,0.9), transparent);
    display: flex;
    flex-direction: column;
    justify-content: flex-end;
    padding: 2rem;
    opacity: 0;
    transition: var(--transition);
}

.portfolio-item:hover .item-overlay { opacity: 1; }
.portfolio-item:hover img { transform: scale(1.1); }

.energy-glow {
    position: absolute;
    inset: 0;
    box-shadow: inset 0 0 50px var(--accent);
    opacity: 0;
    transition: var(--transition);
    pointer-events: none;
}

.portfolio-item:hover .energy-glow { opacity: 0.3; }

/* 3D Featured */
.featured-3d {
    padding: 100px 0;
    background: radial-gradient(circle at center, #1a1a1e, #050505);
}

.card-3d-container {
    display: flex;
    justify-content: center;
    perspective: 1500px;
    margin-top: 4rem;
}

.card-3d {
    width: 350px;
    height: 500px;
    transform-style: preserve-3d;
    transition: transform 0.1s ease-out;
    position: relative;
}

.card-3d-inner {
    width: 100%;
    height: 100%;
    border-radius: 24px;
    overflow: hidden;
    background: var(--surface);
    border: 1px solid rgba(255, 255, 255, 0.1);
    transform: translateZ(20px);
}

.card-3d-front {
    width: 100%;
    height: 100%;
    background-size: cover;
    background-position: center;
    position: relative;
}

.card-info {
    position: absolute;
    bottom: 2rem;
    left: 2rem;
}

/* About Section */
.about {
    padding: 100px 10%;
}

.about-container {
    display: grid;
    grid-template-columns: 1fr 1.2fr;
    gap: 5rem;
    align-items: center;
}

.about-img .img-wrapper {
    position: relative;
    border-radius: 30px;
    overflow: hidden;
}

.about-img img {
    width: 100%;
    filter: grayscale(1);
    transition: var(--transition);
}

.about-img:hover img { filter: grayscale(0); }

/* Services */
.services {
    padding: 100px 10%;
    background: var(--surface);
}

.services-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 2.5rem;
    margin-top: 4rem;
}

.service-card {
    padding: 3rem 2rem;
    background: var(--bg);
    border-radius: 24px;
    border: 1px solid rgba(255, 255, 255, 0.05);
    transition: var(--transition);
    text-align: center;
}

.service-card:hover {
    transform: translateY(-10px);
    border-color: var(--accent);
}

.service-icon {
    width: 48px;
    height: 48px;
    color: var(--accent);
    margin-bottom: 1.5rem;
}

/* Contact */
.contact {
    padding: 100px 10%;
}

.contact-card {
    background: var(--surface);
    border-radius: 40px;
    display: grid;
    grid-template-columns: 1fr 1fr;
    overflow: hidden;
    border: 1px solid rgba(255, 255, 255, 0.1);
}

.contact-info {
    padding: 4rem;
    background: linear-gradient(135deg, var(--accent), #b21f1f);
    color: white;
}

.contact-form {
    padding: 4rem;
}

.input-group { margin-bottom: 1.5rem; }

.input-group input, .input-group textarea {
    width: 100%;
    padding: 1rem;
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 12px;
    color: white;
    font-family: inherit;
    outline: none;
}

.input-group input:focus { border-color: var(--accent); }

/* Footer */
footer {
    padding: 3rem;
    text-align: center;
    border-top: 1px solid rgba(255, 255, 255, 0.05);
    color: var(--text-dim);
}

/* Responsive */
@media (max-width: 992px) {
    .contact-card { grid-template-columns: 1fr; }
    .about-container { grid-template-columns: 1fr; text-align: center; }
    .nav-links { display: none; }
}
