@import url('https://fonts.googleapis.com/css2?family=Outfit:wght@300;400;500;600;700;800&display=swap');

:root {
    --primary: #0ea5e9;
    --primary-dark: #0284c7;
    --primary-light: #7dd3fc;
    --secondary: #94a3b8;
    --accent: #22d3ee;
    --background: #ffffff;
    --surface: #f8fafc;
    --header-bg: #111111;
    --footer-bg: #000000;
    --text-main: #0f172a;
    --text-muted: #475569;
    --white: #ffffff;
    --header-height: 80px;
    --shadow: 0 10px 30px -10px rgba(0, 0, 0, 0.1);
    --transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

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

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

h1, h2, h3, h4 {
    font-weight: 700;
    line-height: 1.2;
}

a {
    text-decoration: none;
    color: inherit;
    transition: var(--transition);
}

ul { list-style: none; }

img { max-width: 100%; }

/* ===================== LAYOUT ===================== */
.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 2rem;
}

.section {
    padding: 80px 0;
}

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

/* ===================== BUTTONS ===================== */
.btn {
    display: inline-block;
    padding: 12px 32px;
    border-radius: 8px;
    font-weight: 600;
    cursor: pointer;
    transition: var(--transition);
    border: none;
    font-size: 1rem;
    font-family: 'Outfit', sans-serif;
}

.btn-primary {
    background: var(--primary);
    color: var(--white);
    box-shadow: 0 4px 14px 0 rgba(37, 99, 235, 0.39);
}

.btn-primary:hover {
    background: var(--primary-dark);
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(37, 99, 235, 0.23);
}

.btn-outline {
    background: transparent;
    border: 2px solid var(--primary);
    color: var(--primary);
}

.btn-outline:hover {
    background: var(--primary);
    color: var(--white);
}

/* ===================== HEADER / NAVBAR ===================== */
header {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: var(--header-height);
    z-index: 1000;
    background: var(--header-bg);
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
    transition: var(--transition);
}

.logo {
    font-size: 1.6rem;
    font-weight: 700;
    color: var(--primary);
    text-decoration: none;
    display: flex;
    align-items: center;
    gap: 8px;
    white-space: nowrap;
}

nav {
    display: flex;
    justify-content: space-between;
    align-items: center;
    height: 100%;
}

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

.nav-links a {
    color: #ffffff;
    text-decoration: none;
    font-weight: 500;
    font-size: 0.95rem;
    padding: 10px 0;
    transition: var(--transition);
}

.nav-links a:hover,
.nav-links a.active {
    color: var(--primary);
}

/* Dropdown */
.dropdown {
    position: relative;
    display: inline-block;
}

.dropdown-content {
    display: none;
    position: absolute;
    background-color: #ffffff;
    min-width: 240px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.15);
    z-index: 1001;
    top: 100%;
    left: 0;
    border-radius: 12px;
    overflow: hidden;
    border: 1px solid #e2e8f0;
    margin-top: 10px;
    padding: 8px 0;
}

.dropdown-content a {
    color: #1e293b !important;
    padding: 12px 20px;
    text-decoration: none;
    display: block;
    font-size: 0.9rem;
    font-weight: 500;
    transition: all 0.2s ease;
}

.dropdown-content a:hover {
    background-color: #f0f9ff;
    color: var(--primary) !important;
    padding-left: 25px;
}

.dropdown:hover .dropdown-content {
    display: block;
    animation: fadeInUp 0.3s ease forwards;
}

.dropbtn i {
    font-size: 0.8rem;
    margin-left: 5px;
    transition: transform 0.3s ease;
}

.dropdown:hover .dropbtn i {
    transform: rotate(180deg);
}

/* Header contact info */
.header-info {
    display: flex;
    align-items: center;
    gap: 20px;
    color: #ffffff;
    flex-shrink: 0;
}

.contact-item {
    display: flex;
    align-items: center;
    gap: 12px;
}

.contact-icon {
    width: 40px;
    height: 40px;
    background: rgba(14, 165, 233, 0.1);
    border: 1px solid var(--primary);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--primary);
    font-size: 1.1rem;
}

.contact-details span {
    display: block;
    font-size: 0.9rem;
    font-weight: 700;
    line-height: 1.2;
}

.contact-details small {
    display: block;
    font-size: 0.75rem;
    color: var(--primary);
    font-weight: 500;
}

/* ===================== HAMBURGER BUTTON ===================== */
.hamburger {
    display: none;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    gap: 5px;
    width: 44px;
    height: 44px;
    cursor: pointer;
    background: none;
    border: none;
    z-index: 1100;
    padding: 4px;
}

.hamburger span {
    display: block;
    width: 26px;
    height: 3px;
    background: #ffffff;
    border-radius: 3px;
    transition: var(--transition);
}

.hamburger.open span:nth-child(1) { transform: translateY(8px) rotate(45deg); }
.hamburger.open span:nth-child(2) { opacity: 0; }
.hamburger.open span:nth-child(3) { transform: translateY(-8px) rotate(-45deg); }

/* ===================== MOBILE NAV DRAWER ===================== */
.mobile-nav {
    display: none;
    position: fixed;
    top: var(--header-height);
    left: 0;
    width: 100%;
    height: calc(100vh - var(--header-height));
    background: #111111;
    z-index: 999;
    overflow-y: auto;
    padding: 10px 0 40px;
    flex-direction: column;
}

.mobile-nav.open { display: flex; }

.mobile-nav > ul {
    list-style: none;
    padding: 0 24px;
}

.mobile-nav > ul > li {
    border-bottom: 1px solid rgba(255,255,255,0.08);
}

.mobile-nav > ul > li > a {
    display: block;
    color: #ffffff;
    font-size: 1.1rem;
    font-weight: 500;
    padding: 16px 0;
    transition: color 0.2s;
}

.mobile-nav > ul > li > a:hover,
.mobile-nav > ul > li > a.active {
    color: var(--primary);
}

.mobile-services-toggle {
    display: flex;
    justify-content: space-between;
    align-items: center;
    color: #ffffff;
    font-size: 1.1rem;
    font-weight: 500;
    padding: 16px 0;
    cursor: pointer;
    background: none;
    border: none;
    width: 100%;
    text-align: left;
    font-family: 'Outfit', sans-serif;
}

.mobile-services-toggle i {
    transition: transform 0.3s;
    color: var(--primary);
    font-size: 0.85rem;
}

.mobile-services-toggle.open i { transform: rotate(180deg); }

.mobile-sub { display: none; padding-left: 16px; }
.mobile-sub.open { display: block; }

.mobile-sub a {
    display: block;
    font-size: 0.95rem;
    padding: 11px 0;
    color: #cbd5e1;
    border-bottom: 1px solid rgba(255,255,255,0.05);
}

.mobile-sub a:hover { color: var(--primary); }

.mobile-email {
    margin-top: 20px;
    padding: 0 24px;
}

.mobile-email a {
    display: flex;
    align-items: center;
    gap: 12px;
    color: var(--primary);
    font-size: 0.95rem;
    font-weight: 600;
    padding: 14px 20px;
    background: rgba(14, 165, 233, 0.1);
    border-radius: 12px;
    border: 1px solid rgba(14, 165, 233, 0.2);
}

/* ===================== HERO ===================== */
.hero {
    height: 100vh;
    min-height: 500px;
    background: linear-gradient(rgba(0, 0, 0, 0.7), rgba(0, 0, 0, 0.5)), url('assets/hero_main.png');
    background-size: cover;
    background-position: center;
    display: flex;
    align-items: center;
    color: var(--white);
    padding-top: var(--header-height);
}

.hero-content { max-width: 600px; }

.hero h1 {
    font-size: 5rem;
    line-height: 1.1;
    max-width: 800px;
    margin-bottom: 1.5rem;
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
}

.hero p {
    font-size: 1.25rem;
    color: var(--text-muted);
    margin-bottom: 2rem;
}

.hero-btns {
    display: flex;
    flex-wrap: wrap;
    gap: 15px;
}

/* ===================== CARDS ===================== */
.card {
    background: var(--white);
    padding: 40px;
    border-radius: 20px;
    border: 1px solid var(--border);
    transition: var(--transition);
    height: 100%;
}

.card:hover {
    transform: translateY(-10px);
    box-shadow: var(--shadow);
    border-color: var(--primary-light);
}

.card-icon {
    width: 60px;
    height: 60px;
    background: rgba(37, 99, 235, 0.1);
    color: var(--primary);
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 24px;
    font-size: 1.5rem;
}

/* ===================== SERVICES GRID ===================== */
.services-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 30px;
    margin-top: 50px;
}

/* ===================== TECH STACK ===================== */
.tech-stack-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(140px, 1fr));
    gap: 20px;
    margin-top: 50px;
}

.tech-card {
    background: #fffafa;
    padding: 25px;
    border-radius: 12px;
    text-align: center;
    transition: var(--transition);
    border: 1px solid rgba(255, 255, 255, 0.5);
}

.tech-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.05);
    background: var(--white);
    border-color: var(--primary-light);
}

.tech-card i, .tech-card img {
    font-size: 2.5rem;
    color: var(--primary);
    margin-bottom: 15px;
    display: block;
}

.tech-card span {
    font-weight: 600;
    color: var(--text-main);
}

/* ===================== SERVICE IMAGES ===================== */
.service-images {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 20px;
    margin-top: 25px;
}

.service-img {
    width: 100%;
    height: 180px;
    object-fit: cover;
    border-radius: 12px;
    transition: var(--transition);
}

.service-img:hover { transform: scale(1.05); }

/* ===================== FOOTER ===================== */
footer {
    background: var(--footer-bg);
    color: #ffffff;
    padding: 80px 0 40px;
}

.footer-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 40px;
    margin-bottom: 60px;
}

.footer-logo {
    color: var(--white);
    font-size: 1.5rem;
    font-weight: 800;
    margin-bottom: 20px;
    display: block;
}

.footer-links h4 { margin-bottom: 24px; font-size: 1.2rem; }

.footer-links a {
    display: block;
    color: #94a3b8;
    margin-bottom: 12px;
}

.footer-links a:hover { color: var(--white); }

.footer-bottom {
    padding-top: 40px;
    border-top: 1px solid #1e293b;
    text-align: center;
    color: #64748b;
}

/* ===================== ANIMATIONS ===================== */
@keyframes fadeIn {
    from { opacity: 0; transform: translateY(10px); }
    to   { opacity: 1; transform: translateY(0); }
}

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

.reveal { animation: fadeInUp 0.8s ease forwards; }

/* ===================== RESPONSIVE — TABLET (≤1100px) ===================== */
@media (max-width: 1100px) {
    .nav-links { gap: 15px; }
    .contact-details small { display: none; }
}

/* ===================== RESPONSIVE — MOBILE NAV (≤900px) ===================== */
@media (max-width: 900px) {
    .nav-links { display: none; }
    .header-info { display: none; }
    .hamburger { display: flex; }
}

/* ===================== RESPONSIVE — TABLET CONTENT (≤768px) ===================== */
@media (max-width: 768px) {
    .section { padding: 50px 0; }

    /* Hero */
    .hero h1 { font-size: 2.6rem; }
    .hero p  { font-size: 1rem; }
    .hero-btns a {
        margin-left: 0 !important;
        padding: 12px 24px !important;
        font-size: 1rem !important;
    }

    /* Generic inline-style grid overrides */
    .responsive-grid {
        grid-template-columns: 1fr !important;
    }

    /* About/Index two-column flex → column */
    .flex-responsive {
        flex-direction: column !important;
        gap: 30px !important;
    }
    .flex-responsive > div {
        min-width: unset !important;
        width: 100% !important;
    }

    /* Headings */
    .h-xl  { font-size: 2rem !important; }
    .h-lg  { font-size: 1.8rem !important; }
    .h-md  { font-size: 1.5rem !important; }
}

/* ===================== RESPONSIVE — SMALL MOBILE (≤480px) ===================== */
@media (max-width: 480px) {
    .container { padding: 0 1rem; }
    .logo { font-size: 1.3rem; }
    .hero h1 { font-size: 1.9rem; }
    .tech-stack-grid { grid-template-columns: repeat(2, 1fr); }
}