/* ================================================================
   Influhub – Custom CSS
   Bootstrap 5 is loaded via CDN; this file adds brand tokens
   and custom component styles.
================================================================ */

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

/* ── CSS Variables ───────────────────────────────────────────── */
:root {
    --ih-primary:      #6C5CE7;
    --ih-primary-dark: #5A4BD1;
    --ih-secondary:    #A29BFE;
    --ih-accent:       #FD79A8;
    --ih-dark:         #1A1A2E;
    --ih-text:         #2D3436;
    --ih-muted:        #636E72;
    --ih-bg:           #F8F9FF;
    --ih-card-bg:      #FFFFFF;
    --ih-border:       #E2E8F0;
    --ih-radius:       12px;
    --ih-radius-sm:    8px;
    --ih-shadow:       0 4px 24px rgba(108,92,231,0.08);
    --ih-shadow-hover: 0 8px 40px rgba(108,92,231,0.18);
    --ih-transition:   0.25s ease;
}

/* ── Base ────────────────────────────────────────────────────── */
*, *::before, *::after { box-sizing: border-box; }

body {
    font-family: 'Inter', system-ui, -apple-system, sans-serif;
    background: var(--ih-bg);
    color: var(--ih-text);
    line-height: 1.65;
    font-size: 15px;
}

a { color: var(--ih-primary); text-decoration: none; }
a:hover { color: var(--ih-primary-dark); }

img { max-width: 100%; height: auto; }

/* ── Navbar ──────────────────────────────────────────────────── */
.ih-navbar {
    background: #ffffff;
    box-shadow: 0 1px 0 var(--ih-border);
    padding: 14px 0;
}

.ih-navbar .navbar-brand {
    font-size: 1.5rem;
    font-weight: 800;
    background: linear-gradient(135deg, var(--ih-primary), var(--ih-accent));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.ih-navbar .nav-link {
    font-weight: 500;
    color: var(--ih-text) !important;
    transition: color var(--ih-transition);
}
.ih-navbar .nav-link:hover { color: var(--ih-primary) !important; }

/* ── Buttons ─────────────────────────────────────────────────── */
.btn-ih {
    background: linear-gradient(135deg, var(--ih-primary), var(--ih-primary-dark));
    color: #fff;
    border: none;
    border-radius: 50px;
    padding: 10px 26px;
    font-weight: 600;
    font-size: 0.92rem;
    letter-spacing: 0.02em;
    transition: all var(--ih-transition);
    box-shadow: 0 4px 15px rgba(108,92,231,0.3);
}
.btn-ih:hover {
    color: #fff;
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(108,92,231,0.45);
}
.btn-ih:active { transform: translateY(0); }

.btn-ih-outline {
    background: transparent;
    border: 2px solid var(--ih-primary);
    color: var(--ih-primary);
    border-radius: 50px;
    padding: 8px 24px;
    font-weight: 600;
    font-size: 0.92rem;
    transition: all var(--ih-transition);
}
.btn-ih-outline:hover {
    background: var(--ih-primary);
    color: #fff;
    transform: translateY(-2px);
}

/* ── Cards ───────────────────────────────────────────────────── */
.ih-card {
    background: var(--ih-card-bg);
    border: 1px solid var(--ih-border);
    border-radius: var(--ih-radius);
    box-shadow: var(--ih-shadow);
    transition: box-shadow var(--ih-transition), transform var(--ih-transition);
    overflow: hidden;
}
.ih-card:hover {
    box-shadow: var(--ih-shadow-hover);
    transform: translateY(-3px);
}

.ih-card-img {
    width: 100%;
    height: 180px;
    object-fit: cover;
}

/* ── Stat Cards (Dashboard) ──────────────────────────────────── */
.stat-card {
    border-radius: var(--ih-radius);
    padding: 24px;
    color: #fff;
    position: relative;
    overflow: hidden;
}
.stat-card::after {
    content: '';
    position: absolute;
    top: -30px; right: -30px;
    width: 110px; height: 110px;
    border-radius: 50%;
    background: rgba(255,255,255,0.12);
}
.stat-card .stat-icon { font-size: 2rem; opacity: 0.9; }
.stat-card .stat-value { font-size: 2rem; font-weight: 800; line-height: 1; }
.stat-card .stat-label { font-size: 0.82rem; opacity: 0.85; font-weight: 500; margin-top: 4px; }

.stat-purple  { background: linear-gradient(135deg, #6C5CE7, #a29bfe); }
.stat-pink    { background: linear-gradient(135deg, #fd79a8, #e84393); }
.stat-teal    { background: linear-gradient(135deg, #00cec9, #00b894); }
.stat-orange  { background: linear-gradient(135deg, #fdcb6e, #e17055); }

/* ── Hero Section ────────────────────────────────────────────── */
.ih-hero {
    background: linear-gradient(135deg, #1A1A2E 0%, #16213E 50%, #0F3460 100%);
    color: #fff;
    padding: 100px 0 90px;
    position: relative;
    overflow: hidden;
}
.ih-hero::before {
    content: '';
    position: absolute;
    top: -50%; right: -10%;
    width: 600px; height: 600px;
    border-radius: 50%;
    background: radial-gradient(circle, rgba(108,92,231,0.25) 0%, transparent 70%);
    pointer-events: none;
}
.ih-hero::after {
    content: '';
    position: absolute;
    bottom: -30%; left: -5%;
    width: 400px; height: 400px;
    border-radius: 50%;
    background: radial-gradient(circle, rgba(253,121,168,0.15) 0%, transparent 70%);
    pointer-events: none;
}
.ih-hero h1 {
    font-size: clamp(2rem, 5vw, 3.4rem);
    font-weight: 800;
    line-height: 1.15;
}
.ih-hero .hero-badge {
    display: inline-block;
    background: rgba(108,92,231,0.25);
    border: 1px solid rgba(108,92,231,0.4);
    color: var(--ih-secondary);
    font-size: 0.8rem;
    font-weight: 600;
    padding: 5px 14px;
    border-radius: 50px;
    margin-bottom: 20px;
    letter-spacing: 0.05em;
    text-transform: uppercase;
}
.ih-hero .lead { color: rgba(255,255,255,0.75); font-size: 1.1rem; }
.ih-hero-img {
    border-radius: var(--ih-radius);
    box-shadow: 0 30px 80px rgba(0,0,0,0.5);
}

/* ── Section ─────────────────────────────────────────────────── */
.ih-section { padding: 80px 0; }
.ih-section-sm { padding: 50px 0; }
.section-label {
    font-size: 0.78rem;
    font-weight: 700;
    letter-spacing: 0.12em;
    text-transform: uppercase;
    color: var(--ih-primary);
    margin-bottom: 10px;
}
.ih-section h2 {
    font-size: clamp(1.6rem, 3vw, 2.2rem);
    font-weight: 800;
    color: var(--ih-dark);
}

/* ── How it Works Steps ──────────────────────────────────────── */
.ih-step-num {
    width: 52px; height: 52px;
    border-radius: 50%;
    background: linear-gradient(135deg, var(--ih-primary), var(--ih-primary-dark));
    color: #fff;
    font-size: 1.3rem;
    font-weight: 800;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 16px;
    box-shadow: 0 8px 20px rgba(108,92,231,0.35);
}

/* ── Feature Icons ───────────────────────────────────────────── */
.feat-icon {
    width: 56px; height: 56px;
    border-radius: var(--ih-radius-sm);
    background: linear-gradient(135deg, var(--ih-primary), var(--ih-secondary));
    color: #fff;
    font-size: 1.4rem;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 16px;
    flex-shrink: 0;
}

/* ── Pricing Cards ───────────────────────────────────────────── */
.pricing-card {
    border: 2px solid var(--ih-border);
    border-radius: var(--ih-radius);
    padding: 36px 28px;
    background: #fff;
    transition: all var(--ih-transition);
    position: relative;
}
.pricing-card.popular {
    border-color: var(--ih-primary);
    transform: scale(1.03);
}
.pricing-badge {
    position: absolute;
    top: -13px; left: 50%; transform: translateX(-50%);
    background: linear-gradient(135deg, var(--ih-primary), var(--ih-accent));
    color: #fff;
    font-size: 0.72rem;
    font-weight: 700;
    padding: 3px 16px;
    border-radius: 50px;
    white-space: nowrap;
    letter-spacing: 0.06em;
    text-transform: uppercase;
}
.pricing-price {
    font-size: 2.8rem;
    font-weight: 800;
    color: var(--ih-dark);
    line-height: 1;
}

/* ── Dashboard Sidebar ───────────────────────────────────────── */
.ih-sidebar {
    width: 240px;
    min-height: 100vh;
    background: var(--ih-dark);
    position: fixed;
    left: 0; top: 0;
    z-index: 100;
    display: flex;
    flex-direction: column;
    padding: 0;
    transition: width 0.3s ease;
}
.ih-sidebar .sidebar-brand {
    padding: 22px 24px 16px;
    font-size: 1.25rem;
    font-weight: 800;
    background: linear-gradient(135deg, var(--ih-primary), var(--ih-accent));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    border-bottom: 1px solid rgba(255,255,255,0.08);
}
.ih-sidebar .sidebar-role {
    padding: 8px 24px 16px;
    font-size: 0.72rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    color: rgba(255,255,255,0.35);
}
.ih-sidebar .nav-link {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 10px 24px;
    color: rgba(255,255,255,0.65) !important;
    font-size: 0.88rem;
    font-weight: 500;
    border-left: 3px solid transparent;
    transition: all var(--ih-transition);
}
.ih-sidebar .nav-link:hover,
.ih-sidebar .nav-link.active {
    color: #fff !important;
    background: rgba(108,92,231,0.15);
    border-left-color: var(--ih-primary);
}
.ih-sidebar .nav-link i { width: 18px; text-align: center; font-size: 1rem; }
.sidebar-divider {
    border-top: 1px solid rgba(255,255,255,0.08);
    margin: 12px 0;
}
.sidebar-section-label {
    padding: 10px 24px 4px;
    font-size: 0.68rem;
    font-weight: 700;
    letter-spacing: 0.1em;
    text-transform: uppercase;
    color: rgba(255,255,255,0.3);
}

/* ── Dashboard Main ──────────────────────────────────────────── */
.ih-main {
    margin-left: 240px;
    min-height: 100vh;
    background: var(--ih-bg);
}
.ih-topbar {
    background: #fff;
    border-bottom: 1px solid var(--ih-border);
    padding: 14px 28px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    position: sticky;
    top: 0;
    z-index: 50;
}
.ih-topbar h5 { font-weight: 700; margin: 0; font-size: 1rem; color: var(--ih-dark); }
.ih-content { padding: 28px; }

/* ── Tables ──────────────────────────────────────────────────── */
.ih-table {
    background: #fff;
    border-radius: var(--ih-radius);
    overflow: hidden;
    box-shadow: var(--ih-shadow);
}
.ih-table thead th {
    background: var(--ih-bg);
    font-size: 0.78rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.06em;
    color: var(--ih-muted);
    border-bottom: 1px solid var(--ih-border);
    padding: 14px 16px;
}
.ih-table tbody td {
    padding: 14px 16px;
    vertical-align: middle;
    border-bottom: 1px solid var(--ih-border);
    font-size: 0.9rem;
}
.ih-table tbody tr:last-child td { border-bottom: none; }
.ih-table tbody tr:hover { background: var(--ih-bg); }

/* ── Campaign Browse Cards ───────────────────────────────────── */
.campaign-card {
    border: 1px solid var(--ih-border);
    border-radius: var(--ih-radius);
    background: #fff;
    overflow: hidden;
    transition: all var(--ih-transition);
    height: 100%;
    display: flex;
    flex-direction: column;
}
.campaign-card:hover {
    box-shadow: var(--ih-shadow-hover);
    transform: translateY(-4px);
}
.campaign-card .card-img-top {
    height: 170px;
    object-fit: cover;
}
.campaign-card .card-body { flex: 1; }
.campaign-platform-tag {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    font-size: 0.72rem;
    font-weight: 600;
    background: rgba(108,92,231,0.1);
    color: var(--ih-primary);
    padding: 3px 10px;
    border-radius: 50px;
    margin-bottom: 8px;
}

/* ── Status Badges ───────────────────────────────────────────── */
.badge { font-weight: 600; font-size: 0.73rem; letter-spacing: 0.02em; }

/* ── Forms ───────────────────────────────────────────────────── */
.ih-form-card {
    background: #fff;
    border-radius: var(--ih-radius);
    padding: 32px;
    box-shadow: var(--ih-shadow);
    border: 1px solid var(--ih-border);
}
.form-label { font-weight: 600; font-size: 0.88rem; color: var(--ih-text); }
.form-control, .form-select {
    border-radius: var(--ih-radius-sm);
    border: 1.5px solid var(--ih-border);
    font-size: 0.92rem;
    padding: 10px 14px;
    transition: border-color 0.2s, box-shadow 0.2s;
}
.form-control:focus, .form-select:focus {
    border-color: var(--ih-primary);
    box-shadow: 0 0 0 3px rgba(108,92,231,0.15);
}

/* ── Footer ──────────────────────────────────────────────────── */
.ih-footer {
    background: var(--ih-dark);
    color: rgba(255,255,255,0.6);
    padding: 60px 0 30px;
}
.ih-footer .footer-brand {
    font-size: 1.5rem;
    font-weight: 800;
    background: linear-gradient(135deg, var(--ih-primary), var(--ih-accent));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}
.ih-footer a { color: rgba(255,255,255,0.55); font-size: 0.88rem; }
.ih-footer a:hover { color: #fff; }
.ih-footer h6 { color: rgba(255,255,255,0.9); font-weight: 700; font-size: 0.85rem; letter-spacing: 0.06em; text-transform: uppercase; }
.footer-divider { border-color: rgba(255,255,255,0.1); margin: 28px 0 20px; }

/* ── Auth Pages ──────────────────────────────────────────────── */
.ih-auth-wrap {
    min-height: 100vh;
    background: linear-gradient(135deg, #1A1A2E 0%, #16213E 60%, #0F3460 100%);
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 40px 16px;
}
.ih-auth-card {
    background: #fff;
    border-radius: var(--ih-radius);
    padding: 40px;
    width: 100%;
    max-width: 460px;
    box-shadow: 0 30px 80px rgba(0,0,0,0.35);
}

/* ── CTA Section ─────────────────────────────────────────────── */
.ih-cta {
    background: linear-gradient(135deg, var(--ih-primary) 0%, var(--ih-primary-dark) 100%);
    color: #fff;
    padding: 80px 0;
    text-align: center;
}

/* ── Responsive ──────────────────────────────────────────────── */
@media (max-width: 768px) {
    .ih-sidebar {
        width: 0;
        overflow: hidden;
    }
    .ih-main {
        margin-left: 0;
    }
    .ih-hero { padding: 70px 0 60px; }
    .pricing-card.popular { transform: none; }
}

/* ── Utilities ───────────────────────────────────────────────── */
.text-purple { color: var(--ih-primary) !important; }
.bg-purple   { background: var(--ih-primary) !important; }
.rounded-ih  { border-radius: var(--ih-radius) !important; }
.fw-800      { font-weight: 800 !important; }
.gap-10      { gap: 10px; }
.avatar-sm { width: 36px; height: 36px; border-radius: 50%; object-fit: cover; }
.avatar-md { width: 56px; height: 56px; border-radius: 50%; object-fit: cover; }
.avatar-lg { width: 80px; height: 80px; border-radius: 50%; object-fit: cover; }
