/* ===============================
   GLOBAL / BASE
================================= */
html {
    scroll-behavior: smooth;
}

body {
    margin: 0;
    font-family: 'Inter', sans-serif;
    background: radial-gradient(circle at top, #050816, #020617 60%);
    color: #e5e7eb;
    overflow-x: hidden;
    letter-spacing: 0.3px;
    line-height: 1.6;
}

body {
    animation: fadePage 0.6s ease;
}

@keyframes fadePage {
    from {
        opacity: 0;
        transform: translateY(10px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

h1, h2, h3 {
    font-weight: 600;
}

/* CONTAINER (layout control) */
.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

#loader {
    position: fixed;
    width: 100%;
    height: 100%;
    background: #020617;
    z-index: 2000;
    transition: opacity 0.5s ease;
}

/* ===============================
   NAVBAR (FIXED)
================================= */

.nav {
    padding: 30px 0;

    backdrop-filter: blur(10px);
    background: rgba(2, 6, 23, 0.7);

    position: sticky;
    top: 10;
    z-index: 100;

    width: 100%;
}

.nav::after {
    content: "";
    position: absolute;
    bottom: 0;
    left: 0;
    width: 100%;
    height: 1px;

    background: linear-gradient(
        to right,
        transparent,
        rgba(185,28,28,0.6),
        transparent
    );
}

.nav-wrapper {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;

    display: flex;
    justify-content: space-between;
    align-items: center;
}

/* NAV LINKS */
.nav-links a::after {
    content: "";
    position: absolute;
    left: 0;
    bottom: -5px;
    width: 0%;
    height: 1px;
    background: #b91c1c;
    transition: 0.3s;
}

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

.nav-links {
    display: flex;
    gap: 25px; /* 💥 THIS FIXES EVERYTHING */
}

.nav-links a {
    color: #b91c1c;
    text-decoration: none;
}

/* LANGUAGE */
.lang {
    display: flex;
    align-items: center;
}

/* LOGO */
.logo {
   font-size: 1.2rem;
    font-weight: bold;
    letter-spacing: 2px;
    text-decoration: none;
    color: #e5e7eb;
    transition: 0.3s;
}

.logo:hover {
    color: #b91c1c;
}

/* ===============================
   HERO SECTION
================================= */

.hero {
    height: 100vh;
    display: flex;
    justify-content: center;
    align-items: center;
    text-align: center;
}

.center {
    max-width: 800px;
}

/* GLOW TEXT  CURSOR*/
.glow {
    color: #b91c1c;
    text-shadow:
        0 0 10px rgba(185,28,28,0.5),
        0 0 20px rgba(185,28,28,0.4),
        0 0 40px rgba(185,28,28,0.3);
}

.cursor-glow {
    position: fixed;
    width: 300px;
    height: 300px;
    pointer-events: none;
    border-radius: 50%;
    background: radial-gradient(circle, rgba(185,28,28,0.15), transparent 70%);
    z-index: 0;
    transform: translate(-50%, -50%);
}


.hero h1 {
    font-size: 4rem;
}


/* ===============================
   BUTTONS
================================= */

.btn {
    margin-top: 30px;
    display: inline-block;
    background: linear-gradient(90deg, #7f1d1d, #b91c1c);
    padding: 14px 30px;
    border-radius: 12px;
    color: white;
    text-decoration: none;
    transition: 0.3s;
}

.btn:hover {
    transform: translateY(-2px) scale(1.02);
    box-shadow: 0 0 30px rgba(185,28,28,0.4);
}

.btn.small {
    margin-top: 10px;
    padding: 8px 14px;
    font-size: 0.8rem;
}


/* ===============================
   SERVICES
================================= */

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

.card {
    padding: 40px;
    border-radius: 16px;
    background: rgba(255,255,255,0.02);
    border: 1px solid rgba(185,28,28,0.15);
    backdrop-filter: blur(12px);
    transition: 0.4s;
}

.card:hover {
    transform: translateY(-10px) scale(1.02);
    border-color: #b91c1c;
    box-shadow: 0 0 40px rgba(185,28,28,0.2);
}

.card h3 {
    margin-top: 0;
    color: #b91c1c;
}

.card p {
    color: #e5e7eb;
}


/* ===============================
   LANGUAGE SWITCH
================================= */

.lang-link {
    color: #b91c1c;
    opacity: 0.7;
    transition: 0.3s;
}

.lang-link:hover {
    opacity: 1;
}

.lang-link.active {
    opacity: 1;
    font-weight: bold;
}


/* ===============================
   PORTFOLIO
================================= */

.portfolio {
    padding: 100px 0;
}

.section-title {
    font-size: 2rem;
    margin-bottom: 50px;
}


/* FEATURED PROJECT */

.project.featured {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 40px;
    margin-bottom: 80px;
}

.project-info h2 {
    font-size: 2rem;
}


/* TAGS */

.tags span {
    display: inline-block;
    margin: 5px;
    padding: 5px 10px;
    border: 1px solid rgba(185,28,28,0.3);
    border-radius: 6px;
    font-size: 0.8rem;
}


/* LIVE PREVIEW */

.project-preview iframe {
    width: 100%;
    height: 400px;
    border-radius: 10px;
    border: none;
}


/* GRID PROJECTS */

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

.project-card {
    padding: 30px;
    border-radius: 14px;
    border: 1px solid rgba(185,28,28,0.15);
    background: rgba(255,255,255,0.02);
    backdrop-filter: blur(12px);
    transition: 0.3s;
}

.project-card:hover {
    transform: translateY(-6px);
    box-shadow: 0 0 30px rgba(185,28,28,0.2);
}


/* DEMO TAG */

.tag {
    display: inline-block;
    font-size: 0.7rem;
    padding: 4px 8px;
    margin-bottom: 10px;
    border: 1px solid rgba(185,28,28,0.4);
    border-radius: 6px;
    color: #b91c1c;
    opacity: 0.8;
}


/* ===============================
   RESPONSIVE
================================= */

@media (max-width: 900px) {

    .hero h1 {
        font-size: 2.5rem;
    }

    .project.featured {
        grid-template-columns: 1fr;
    }

    .project-preview iframe {
        height: 300px;
    }
}
.nav-links {
    display: flex;
    align-items: center;
}

.lang {
    display: flex;
    align-items: center;
}

/* Crazy Portfolio- HOVER PREVIEW SYSTEM */

.preview-popup {
    position: fixed;
    width: 400px;
    height: 250px;
    pointer-events: none;
    z-index: 999;
    display: none;
    border-radius: 12px;
    overflow: hidden;
    border: 1px solid rgba(185,28,28,0.3);
    box-shadow: 0 0 40px rgba(185,28,28,0.3);
    background: #000;
}

.preview-popup iframe {
    width: 100%;
    height: 100%;
    border: none;
}

/* PROJECT CARD HOVER */

.project-card {
    cursor: pointer;
    position: relative;
}

.project-card:hover,
.card:hover {
    transform: translateY(-8px) scale(1.02);
    box-shadow: 0 0 40px rgba(185,28,28,0.25);
    border-color: #b91c1c;
}

/* FULLSCREEN VIEWER */

.fullscreen-viewer {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;

    background: #020617;
    z-index: 1000;

    display: none;
    flex-direction: column;
}

/* HEADER BAR */

.viewer-header {
    height: 50px;
    display: flex;
    justify-content: flex-end;
    align-items: center;
    padding: 0 20px;

    background: rgba(0,0,0,0.6);
    border-bottom: 1px solid rgba(185,28,28,0.3);
}

/* CLOSE BUTTON */

#closeViewer {
    background: none;
    border: 1px solid #b91c1c;
    color: #b91c1c;
    padding: 6px 12px;
    border-radius: 6px;
    cursor: pointer;
}

/* IFRAME FULLSCREEN */

#viewerFrame {
    flex: 1;
    width: 100%;
    border: none;
}

.viewer-header {
    height: 50px;
    display: flex;
    justify-content: space-between; /* IMPORTANT */
    align-items: center;
    padding: 0 20px;

    background: rgba(0,0,0,0.6);
    border-bottom: 1px solid rgba(185,28,28,0.3);
}

.viewer-hint {
    font-size: 0.8rem;
    opacity: 0.6;
    color: #e5e7eb;
}

.viewer-hint {
    animation: fadeIn 0.5s ease;
}

@keyframes fadeIn {
    from { opacity: 0; transform: translateY(-5px); }
    to { opacity: 0.6; transform: translateY(0); }
}

/* TRUST SECTION */
.trust {
    padding: 80px 20px;
    text-align: center;
}

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

.trust-grid div {
    padding: 20px;
    border: 1px solid rgba(185,28,28,0.2);
    border-radius: 10px;
}
.trust-grid div:hover {
    border-color: #b91c1c;
    box-shadow: 0 0 30px rgba(185,28,28,0.2);
}

/* WHATSAPP BUTTON */
.whatsapp-btn {
    position: fixed;
    bottom: 20px;
    right: 20px;

    background: #25D366;
    color: white;

    width: 50px;
    height: 50px;
    border-radius: 50%;

    display: flex;
    align-items: center;
    justify-content: center;

    font-size: 1.5rem;

    box-shadow: 0 0 20px rgba(0,0,0,0.3);
    z-index: 1000;
}

.footer {
    padding: 100px 0 40px; /* more breathing space */
    margin-top: 100px;
    border-top: 1px solid rgba(185,28,28,0.2);

    background: linear-gradient(
        to top,
        rgba(185,28,28,0.05),
        transparent
    );
}

/* GRID STRUCTURE */
.footer-grid {
    display: grid;
    grid-template-columns: 1.5fr 1fr 1fr; /* 👈 logo gets more space */
    gap: 50px;
    align-items: start;
}

/* COLUMNS */
.footer-col {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

/* ALIGNMENT (more natural now) */
.footer-col:nth-child(1) {
    align-items: flex-start;
}

.footer-col:nth-child(2) {
    align-items: flex-start; /* 👈 less forced center */
    text-align: left;
}

.footer-col:nth-child(3) {
    align-items: flex-start; /* 👈 cleaner layout */
    text-align: left;
}

/* LOGO AREA */
.footer-col h3 .logo {
    font-size: 1.4rem;
    letter-spacing: 2px;
}

/* TEXT */
.footer-col h3,
.footer-col h4 {
    color: #b91c1c;
}

.footer-col p,
.footer-col li,
.footer-col a {
    font-size: 0.9rem;
    opacity: 0.8;
    color: #e5e7eb;
    text-decoration: none;
}

.footer-col ul {
    list-style: none;
    padding: 0;
}

/* HOVER */
.footer-col a:hover {
    opacity: 1;
    color: #b91c1c;
}

/* ===============================
   BOTTOM BAR (FIXED CENTER)
================================= */

.footer-bottom {
    margin-top: 60px;
    padding-top: 20px;
    border-top: 1px solid rgba(185,28,28,0.1);

    display: flex;
    justify-content: center; /* 💥 CENTERED */
    align-items: center;

    font-size: 0.8rem;
    opacity: 0.6;
}

/* Optional: remove hosting alignment issue */
.hosting {
    display: none; /* 👈 hide if not needed */
}

/* ===============================
   MOBILE FIX
================================= */

@media (max-width: 768px) {

    .footer-grid {
        grid-template-columns: 1fr;
        gap: 30px;
        text-align: center;
    }

    .footer-col {
        align-items: center !important;
        text-align: center !important;
    }

    .footer-bottom {
        flex-direction: column;
        gap: 10px;
        text-align: center;
    }
}