/* ─── AforDev Public Frontend — White/Purple Theme (Based on Screenshot) ─── */
@import url('https://fonts.googleapis.com/css2?family=Inter:wght@400;500;600;700;800&display=swap');

:root {
    --primary: #9b51e0;
    --hero-bg: #5f6bdd;
    --hero-dark: #505cce;
    --footer-bg: #3a424e;
    --footer-bottom: #323843;

    --text-dark: #444b55;
    --text-nav: #6b7280;
    --text-light: #ffffff;

    --btn-orange: #ff6b6b;

    --bg: #f8f9fa;
    --surface: #ffffff;
    --border: #eaeaea;
}

body.dark-mode {
    --bg: #0b0c10;
    --surface: #151820;
    --border: #232833;
    --text-dark: #e5e7eb;
    --text-nav: #9ca3af;
    --footer-bg: #06070a;
}

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

html {
    scroll-behavior: smooth;
}

body {
    font-family: 'Inter', sans-serif;
    background: var(--bg);
    color: var(--text-dark);
    line-height: 1.6;
    overflow-x: hidden;
    -webkit-font-smoothing: antialiased;
    transition: background-color 0.3s, color 0.3s;
}

ul {
    list-style: none;
}

a {
    text-decoration: none;
    transition: color 0.2s;
    color: var(--text-dark);
}

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

.container {
    width: 100%;
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 1.5rem;
}

/* ─── Buttons ────────────────────────────────────────────────────────────── */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    padding: 0.7rem 1.8rem;
    border-radius: 6px;
    font-weight: 600;
    font-size: 0.85rem;
    transition: all 0.2s ease;
    cursor: pointer;
    border: none;
}

.btn-orange {
    background: var(--btn-orange);
    color: #fff;
    box-shadow: 0 4px 15px rgba(255, 107, 107, 0.3);
}

.btn-orange:hover {
    background: #fa5c5c;
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(255, 107, 107, 0.4);
}

/* ─── Header & Nav ───────────────────────────────────────────────────────── */
.header {
    background: var(--surface);
    border-bottom: 1px solid var(--border);
    padding: 1.2rem 0;
    position: sticky;
    top: 0;
    z-index: 1000;
    transition: background-color 0.3s, border-color 0.3s;
}

.header-inner {
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.logo {
    display: flex;
    align-items: center;
    font-size: 1.8rem;
    font-weight: 800;
    color: var(--primary);
}

.logo i {
    background: linear-gradient(135deg, #a855f7, #6366f1);
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
}

.nav-links {
    display: flex;
    align-items: center;
    gap: 2rem;
    margin-left: 2rem;
    border-left: 1px solid var(--border);
    padding-left: 2rem;
}

.nav-link {
    color: var(--text-nav);
    font-size: 0.85rem;
    font-weight: 600;
}

.nav-link:hover {
    color: var(--primary);
}

.header-icons {
    display: flex;
    align-items: center;
    gap: 1.5rem;
    margin-left: auto;
}

.header-icons a {
    color: var(--text-nav);
    font-size: 1.1rem;
}

.header-icons a:hover {
    color: var(--hero-bg);
}

/* ─── Hero Section ───────────────────────────────────────────────────────── */
.hero {
    background: var(--hero-bg);
    color: #fff;
    padding: 7rem 0 6rem;
    position: relative;
    overflow: hidden;
}

.hero::after {
    /* Subtle gradient overlay to match screenshot depth */
    content: '';
    position: absolute;
    inset: 0;
    background: linear-gradient(180deg, rgba(255, 255, 255, 0.05) 0%, rgba(0, 0, 0, 0.05) 100%);
    pointer-events: none;
}

.hero-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 4rem;
    align-items: center;
    position: relative;
    z-index: 2;
}

.hero-title {
    font-size: 2.8rem;
    font-weight: 800;
    margin-bottom: 1rem;
    line-height: 1.2;
}

.hero-desc {
    font-size: 1.05rem;
    font-weight: 400;
    opacity: 0.9;
    margin-bottom: 2.5rem;
    line-height: 1.7;
    max-width: 450px;
}

/* ─── Features Band ──────────────────────────────────────────────────────── */
.features-band {
    background: var(--hero-dark);
    color: #fff;
    padding: 4rem 0;
    text-align: center;
}

.features-title {
    font-size: 1.6rem;
    font-weight: 700;
    margin-bottom: 3rem;
}

.features-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 2rem;
}

.feature-item {
    display: flex;
    align-items: flex-start;
    gap: 1rem;
    text-align: left;
}

.feature-icon {
    font-size: 1.8rem;
    font-weight: 300;
    margin-top: 0.2rem;
}

.feature-title {
    font-size: 0.95rem;
    font-weight: 700;
    margin-bottom: 0.3rem;
}

.feature-desc {
    font-size: 0.8rem;
    font-weight: 400;
    opacity: 0.8;
    line-height: 1.5;
}

/* ─── Product Grid ───────────────────────────────────────────────────────── */
.products-section {
    padding: 6rem 0;
    background: var(--surface);
}

.section-header {
    text-align: center;
    margin-bottom: 3rem;
}

.section-title {
    font-size: 2rem;
    color: var(--text-dark);
    font-weight: 800;
}

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

.product-card {
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: 8px;
    overflow: hidden;
    transition: transform 0.2s, box-shadow 0.2s, border-color 0.3s, background-color 0.3s;
    position: relative;
    display: flex;
    flex-direction: column;
}

.product-card:hover {
    transform: translateY(-3px);
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.08);
}

.product-img-wrap {
    width: 100%;
    padding-top: 60%;
    position: relative;
    background: var(--bg);
    border-bottom: 1px solid var(--border);
}

.product-img {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.product-no-img {
    position: absolute;
    inset: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #ccc;
    font-size: 2rem;
}

.product-price {
    position: absolute;
    top: 1rem;
    right: 1rem;
    background: #fff;
    color: var(--hero-bg);
    font-weight: 800;
    padding: 0.4rem 0.8rem;
    border-radius: 4px;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
    font-size: 0.9rem;
    z-index: 2;
}

.product-content {
    padding: 1.5rem;
    flex: 1;
    display: flex;
    flex-direction: column;
}

.product-title {
    font-size: 1.15rem;
    font-weight: 800;
    color: var(--footer-bg);
    margin-bottom: 0.5rem;
}

.product-desc {
    font-size: 0.85rem;
    color: #666;
    margin-bottom: 1.5rem;
    line-height: 1.6;
}

/* ─── Footer ─────────────────────────────────────────────────────────────── */
.footer {
    background: var(--footer-bg);
    color: #fff;
    padding-top: 4rem;
}

.footer-grid {
    display: grid;
    grid-template-columns: 2fr 1fr 1fr;
    gap: 3rem;
    margin-bottom: 3rem;
}

.footer-logo {
    font-size: 2rem;
    color: #a855f7;
    margin-bottom: 1rem;
    display: inline-block;
}

.footer-logo i {
    background: linear-gradient(135deg, #a855f7, #6366f1);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

.footer-desc {
    font-size: 0.85rem;
    color: #a0a5b1;
    margin-bottom: 1.5rem;
    max-width: 320px;
}

.footer-socials {
    display: flex;
    gap: 0.8rem;
}

.footer-socials a {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 36px;
    height: 36px;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 4px;
    color: #fff;
    transition: background 0.2s;
}

.footer-socials a:hover {
    background: rgba(255, 255, 255, 0.2);
}

.footer-col-title {
    font-size: 1rem;
    font-weight: 700;
    margin-bottom: 1.5rem;
    color: #fff;
}

.footer-links li {
    margin-bottom: 0.8rem;
}

.footer-links a {
    color: #a0a5b1;
    font-size: 0.85rem;
}

.footer-links a:hover {
    color: #fff;
}

.footer-bottom {
    background: var(--footer-bottom);
    padding: 1.5rem 0;
    font-size: 0.8rem;
    color: #88909e;
    border-top: 1px solid rgba(255, 255, 255, 0.05);
}

.footer-bottom .container {
    display: flex;
    align-items: center;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 1rem;
}

.footer-bottom-links {
    display: flex;
    gap: 1.5rem;
}

.footer-bottom-links a {
    color: #88909e;
    transition: color 0.2s;
}

.footer-bottom-links a:hover {
    color: #fff;
}

@media (max-width: 992px) {
    .hero-grid {
        grid-template-columns: 1fr;
        text-align: center;
    }

    .hero-desc {
        margin-left: auto;
        margin-right: auto;
    }

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

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

@media (max-width: 768px) {
    .nav-links {
        display: none;
    }
}