/* G2B Circle — public website.
   Visual language: Apple's HIG discipline (clarity, deference, depth,
   system typography, generous whitespace, restrained motion) applied to a
   colorful, information-rich Indian business-directory layout — the same
   brand palette used in the mobile app, so the two feel like one product. */

:root {
    --accent: #1456F0;
    --accent-dark: #0B3FC4;
    --cta: #FF7A1A;
    --whatsapp: #25D366;
    --success: #12B76A;
    --warning: #F79009;
    --danger: #E7393B;

    --bg: #F4F6FB;
    --surface: #FFFFFF;
    --label: #15181F;
    --label-secondary: #6B7280;
    --separator: #E7E9F0;

    --radius-lg: 22px;
    --radius-md: 14px;
    --radius-sm: 10px;
    --shadow-card: 0 1px 2px rgba(16, 24, 40, 0.04), 0 8px 24px rgba(16, 24, 40, 0.06);
    --shadow-nav: 0 1px 0 rgba(16, 24, 40, 0.06);
    --hero-gradient: linear-gradient(135deg, #1456F0 0%, #3B7CF6 100%);
    --max-width: 1160px;
    --transition: 180ms cubic-bezier(0.4, 0, 0.2, 1);
}

@media (prefers-color-scheme: dark) {
    :root:not([data-theme="light"]) {
        --bg: #0B0D12;
        --surface: #1A1D26;
        --label: #F2F3F7;
        --label-secondary: #9AA0AC;
        --separator: #2C303B;
        --shadow-card: 0 1px 2px rgba(0, 0, 0, 0.3), 0 8px 24px rgba(0, 0, 0, 0.35);
    }
}
:root[data-theme="dark"] {
    --bg: #0B0D12;
    --surface: #1A1D26;
    --label: #F2F3F7;
    --label-secondary: #9AA0AC;
    --separator: #2C303B;
    --shadow-card: 0 1px 2px rgba(0, 0, 0, 0.3), 0 8px 24px rgba(0, 0, 0, 0.35);
}

* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }

body {
    margin: 0;
    background: var(--bg);
    color: var(--label);
    font-family: -apple-system, BlinkMacSystemFont, "SF Pro Text", "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
    font-size: 16px;
    line-height: 1.55;
    -webkit-font-smoothing: antialiased;
    text-rendering: optimizeLegibility;
}

img { max-width: 100%; display: block; }
a { color: var(--accent); text-decoration: none; }
a:hover { text-decoration: underline; }
a:focus-visible, button:focus-visible, input:focus-visible, textarea:focus-visible, select:focus-visible {
    outline: 2px solid var(--accent);
    outline-offset: 2px;
}

.container { max-width: var(--max-width); margin: 0 auto; padding: 0 24px; }

/* ---------- Nav ---------- */
.site-nav {
    position: sticky;
    top: 0;
    z-index: 50;
    background: color-mix(in srgb, var(--bg) 85%, transparent);
    backdrop-filter: saturate(180%) blur(16px);
    -webkit-backdrop-filter: saturate(180%) blur(16px);
    box-shadow: var(--shadow-nav);
}
.site-nav .container { display: flex; align-items: center; gap: 28px; height: 64px; }
.brand { display: flex; align-items: center; gap: 10px; font-weight: 800; font-size: 18px; letter-spacing: -0.3px; color: var(--label); }
.brand:hover { text-decoration: none; }
.brand .mark {
    width: 32px; height: 32px;
    object-fit: contain;
    flex-shrink: 0;
}
.nav-links { display: flex; align-items: center; gap: 22px; margin-left: 8px; }
.nav-links a { color: var(--label); font-weight: 500; font-size: 14.5px; }
.nav-links a:hover { color: var(--accent); text-decoration: none; }
.nav-spacer { flex: 1; }
.nav-actions { display: flex; align-items: center; gap: 10px; }
.nav-toggle {
    display: none; align-items: center; justify-content: center;
    width: 40px; height: 40px; border-radius: var(--radius-sm);
    border: 1px solid var(--separator); background: var(--surface); cursor: pointer;
    color: var(--label); font-size: 18px;
}
.nav-links-mobile {
    display: none; flex-direction: column; gap: 2px;
    position: absolute; top: 64px; left: 0; right: 0;
    background: var(--surface); border-bottom: 1px solid var(--separator);
    padding: 8px 24px 16px; box-shadow: var(--shadow-card);
}
.nav-links-mobile a { padding: 12px 4px; color: var(--label); font-weight: 600; border-bottom: 1px solid var(--separator); }
.nav-links-mobile a:last-child { border-bottom: none; }
.nav-links-mobile.open { display: flex; }

@media (max-width: 860px) {
    .nav-links { display: none; }
    .nav-actions .btn { display: none; }
    .nav-toggle { display: flex; }
}
@media (min-width: 861px) {
    .nav-links-mobile { display: none !important; }
}

/* ---------- Buttons ---------- */
.btn {
    display: inline-flex; align-items: center; justify-content: center; gap: 8px;
    padding: 12px 22px; border-radius: 980px; font-weight: 600; font-size: 15px;
    border: none; cursor: pointer; transition: transform var(--transition), background var(--transition), box-shadow var(--transition);
    white-space: nowrap;
}
.btn:hover { text-decoration: none; }
.btn:active { transform: scale(0.97); }
.btn-primary { background: var(--cta); color: #fff; }
.btn-primary:hover { background: #eb6f10; }
.btn-accent { background: var(--accent); color: #fff; }
.btn-accent:hover { background: var(--accent-dark); }
.btn-secondary { background: var(--surface); color: var(--label); border: 1px solid var(--separator); }
.btn-secondary:hover { background: var(--bg); }
.btn-whatsapp { background: var(--whatsapp); color: #fff; }
.btn-whatsapp:hover { filter: brightness(0.95); }
.btn-block { width: 100%; }
.btn-sm { padding: 8px 16px; font-size: 13.5px; }
.btn[disabled] { opacity: 0.6; cursor: not-allowed; }

/* ---------- Hero ---------- */
.hero {
    background: var(--hero-gradient);
    border-radius: 0 0 32px 32px;
    color: #fff;
    padding: 56px 0 80px;
    position: relative;
    overflow: hidden;
}
.hero .container { position: relative; z-index: 1; }
.hero h1 { font-size: clamp(32px, 5vw, 52px); font-weight: 800; letter-spacing: -1px; margin: 0 0 14px; line-height: 1.1; max-width: 720px; }
.hero p.lead { font-size: 18px; color: rgba(255,255,255,0.9); max-width: 560px; margin: 0 0 32px; }
.hero-stats { display: flex; gap: 32px; margin-top: 36px; flex-wrap: wrap; }
.hero-stats .stat b { display: block; font-size: 26px; font-weight: 800; }
.hero-stats .stat span { font-size: 13px; color: rgba(255,255,255,0.8); }

.search-card {
    background: var(--surface);
    border-radius: var(--radius-lg);
    box-shadow: 0 20px 48px rgba(16, 24, 40, 0.22);
    padding: 10px;
    display: flex;
    gap: 8px;
    max-width: 640px;
}
.search-card input {
    flex: 1; border: none; outline: none; background: transparent;
    padding: 14px 16px; font-size: 15px; color: var(--label); font-family: inherit;
}
.search-card select {
    border: none; background: var(--bg); border-radius: var(--radius-sm);
    padding: 0 12px; font-size: 14px; color: var(--label); font-family: inherit;
}

/* ---------- Section headings ---------- */
.section { padding: 56px 0; }
.section-head { display: flex; align-items: baseline; justify-content: space-between; margin-bottom: 24px; gap: 16px; }
.section-head h2 { font-size: 26px; font-weight: 800; letter-spacing: -0.5px; margin: 0; }
.section-head p { color: var(--label-secondary); margin: 6px 0 0; font-size: 15px; }
.section-head .view-all { font-weight: 600; font-size: 14px; white-space: nowrap; }

/* ---------- Category pills / grid ---------- */
.category-flow { display: flex; flex-wrap: wrap; gap: 12px; }
.category-pill {
    display: inline-flex; align-items: center; gap: 10px;
    padding: 10px 16px 10px 10px; border-radius: 999px;
    background: var(--surface); border: 1px solid var(--separator);
    color: var(--label); font-weight: 600; font-size: 14px;
    transition: border-color var(--transition), transform var(--transition), box-shadow var(--transition);
}
.category-pill:hover { text-decoration: none; box-shadow: var(--shadow-card); transform: translateY(-1px); }
.category-pill .icon-badge { width: 34px; height: 34px; font-size: 16px; flex-shrink: 0; }

.category-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); gap: 14px; }
.category-card {
    background: var(--surface); border: 1px solid var(--separator); border-radius: var(--radius-md);
    padding: 20px 14px; text-align: center; color: var(--label);
    transition: box-shadow var(--transition), transform var(--transition);
}
.category-card:hover { text-decoration: none; box-shadow: var(--shadow-card); transform: translateY(-2px); }
.category-card .icon-badge { margin: 0 auto 12px; width: 48px; height: 48px; font-size: 21px; }
.category-card .name { font-weight: 700; font-size: 13.5px; line-height: 1.3; }

.icon-badge {
    display: flex; align-items: center; justify-content: center;
    border-radius: 30%; flex-shrink: 0;
}

/* ---------- Business cards ---------- */
.business-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(280px, 1fr)); gap: 18px; }
.business-card {
    background: var(--surface); border: 1px solid var(--separator); border-radius: var(--radius-lg);
    padding: 18px; color: var(--label); display: flex; flex-direction: column; gap: 12px;
    transition: box-shadow var(--transition), transform var(--transition);
}
.business-card:hover { text-decoration: none; box-shadow: var(--shadow-card); transform: translateY(-2px); }
.business-card .top { display: flex; gap: 14px; align-items: flex-start; }
.business-logo {
    width: 56px; height: 56px; border-radius: var(--radius-sm); object-fit: cover; flex-shrink: 0; background: var(--bg);
}
.business-logo-fallback {
    width: 56px; height: 56px; border-radius: var(--radius-sm); flex-shrink: 0;
    display: flex; align-items: center; justify-content: center; font-size: 22px;
}
.business-card h3 { font-size: 16px; font-weight: 700; margin: 0 0 6px; line-height: 1.3; }
.business-card .meta { display: flex; flex-wrap: wrap; gap: 6px; align-items: center; margin-bottom: 4px; }
.tag {
    display: inline-flex; align-items: center; gap: 4px;
    padding: 3px 10px; border-radius: 999px; font-size: 11.5px; font-weight: 700;
}
.tag-verified { background: rgba(18, 183, 106, 0.12); color: var(--success); }
.business-card .address { color: var(--label-secondary); font-size: 13px; display: flex; gap: 5px; align-items: flex-start; }
.business-card .actions { display: flex; gap: 8px; margin-top: auto; }
.business-card .actions .btn { flex: 1; }

/* ---------- Detail page ---------- */
.detail-cover {
    border-radius: var(--radius-lg); padding: 32px; color: #fff; position: relative; overflow: hidden;
    display: flex; gap: 20px; align-items: flex-end; flex-wrap: wrap;
}
.detail-cover .logo-box {
    width: 88px; height: 88px; border-radius: var(--radius-md); background: #fff;
    display: flex; align-items: center; justify-content: center; overflow: hidden; flex-shrink: 0;
}
.detail-cover .logo-box img { width: 100%; height: 100%; object-fit: cover; }
.detail-cover h1 { font-size: 28px; margin: 0 0 4px; font-weight: 800; letter-spacing: -0.5px; }
.detail-cover .tagline { opacity: 0.9; margin-bottom: 10px; }

.detail-actions { display: flex; gap: 10px; margin: 24px 0; flex-wrap: wrap; }
.detail-actions .btn { min-width: 150px; }

.detail-grid { display: grid; grid-template-columns: 2fr 1fr; gap: 28px; margin-top: 12px; }
@media (max-width: 860px) { .detail-grid { grid-template-columns: 1fr; } }

.card {
    background: var(--surface); border: 1px solid var(--separator); border-radius: var(--radius-lg);
    padding: 24px; margin-bottom: 20px;
}
.card h2 { font-size: 17px; margin: 0 0 12px; font-weight: 800; }
.info-row { display: flex; gap: 6px; padding: 10px 0; border-bottom: 1px solid var(--separator); font-size: 14px; }
.info-row:last-child { border-bottom: none; }
.info-row .k { width: 150px; flex-shrink: 0; color: var(--label-secondary); }
.info-row .v { font-weight: 600; }

.photo-strip { display: flex; gap: 10px; overflow-x: auto; padding-bottom: 6px; }
.photo-strip img { width: 130px; height: 130px; object-fit: cover; border-radius: var(--radius-sm); flex-shrink: 0; }

.sticky-side { position: sticky; top: 84px; }

/* ---------- Forms ---------- */
.form-group { margin-bottom: 18px; }
.form-group label { display: block; font-weight: 600; font-size: 13.5px; margin-bottom: 7px; }
.form-group .hint { color: var(--label-secondary); font-size: 12.5px; margin-top: 5px; }
input[type=text], input[type=email], input[type=password], input[type=number],
input[type=date], input[type=time], input[type=url], input[type=tel], input[type=file],
select, textarea {
    width: 100%; padding: 12px 14px; border-radius: var(--radius-sm);
    border: 1px solid var(--separator); background: var(--bg); font-size: 14.5px;
    font-family: inherit; color: var(--label);
}
input:focus, select:focus, textarea:focus { outline: 2px solid var(--accent); outline-offset: 1px; background: var(--surface); }
textarea { resize: vertical; min-height: 100px; }
.grid-2 { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }
@media (max-width: 600px) { .grid-2 { grid-template-columns: 1fr; } }
.checkbox-row { display: flex; align-items: flex-start; gap: 10px; font-size: 13.5px; }
.checkbox-row input { width: auto; margin-top: 3px; }
.chip-choices { display: flex; flex-wrap: wrap; gap: 8px; }
.chip-choice { position: relative; }
.chip-choice input { position: absolute; opacity: 0; inset: 0; cursor: pointer; margin: 0; width: 100%; height: 100%; }
.chip-choice span {
    display: inline-block; padding: 8px 14px; border-radius: 999px; border: 1px solid var(--separator);
    font-size: 13px; font-weight: 600; background: var(--surface);
}
.chip-choice input:checked + span { background: var(--accent); border-color: var(--accent); color: #fff; }

.form-section { border-left: 3px solid var(--accent); }
.form-section .head { display: flex; align-items: center; gap: 10px; margin-bottom: 16px; }
.form-section .head .icon-badge { width: 34px; height: 34px; font-size: 16px; }
.form-section .head h3 { margin: 0; font-size: 15.5px; font-weight: 800; }

/* ---------- Alerts / badges ---------- */
.alert { padding: 14px 18px; border-radius: var(--radius-md); margin-bottom: 20px; font-weight: 500; font-size: 14px; }
.alert-success { background: rgba(18,183,106,0.1); color: #0d7a49; }
.alert-error { background: rgba(231,57,59,0.1); color: #a8241a; }
.badge { display: inline-block; padding: 4px 12px; border-radius: 999px; font-size: 12px; font-weight: 700; }
.badge-pending { background: rgba(247,144,9,0.12); color: var(--warning); }
.badge-approved { background: rgba(18,183,106,0.12); color: var(--success); }
.badge-rejected { background: rgba(231,57,59,0.12); color: var(--danger); }

/* ---------- Empty / misc ---------- */
.empty-state { text-align: center; padding: 60px 20px; color: var(--label-secondary); }
.empty-state .icon-badge { margin: 0 auto 16px; width: 64px; height: 64px; font-size: 26px; }
.pagination { display: flex; gap: 6px; margin-top: 28px; flex-wrap: wrap; }
.pagination a, .pagination span { padding: 9px 15px; border-radius: var(--radius-sm); background: var(--surface); border: 1px solid var(--separator); font-size: 13.5px; font-weight: 600; }
.pagination .current { background: var(--accent); color: #fff; border-color: var(--accent); }

/* ---------- Footer ---------- */
.site-footer { border-top: 1px solid var(--separator); padding: 48px 0 32px; margin-top: 40px; color: var(--label-secondary); font-size: 13.5px; }
.footer-grid { display: grid; grid-template-columns: 2fr 1fr 1fr; gap: 32px; margin-bottom: 32px; }
@media (max-width: 700px) { .footer-grid { grid-template-columns: 1fr; } }
.footer-grid h4 { color: var(--label); font-size: 13.5px; margin: 0 0 12px; }
.footer-grid ul { list-style: none; padding: 0; margin: 0; }
.footer-grid li { margin-bottom: 8px; }
.footer-grid a { color: var(--label-secondary); }
.footer-bottom { display: flex; justify-content: space-between; flex-wrap: wrap; gap: 8px; padding-top: 24px; border-top: 1px solid var(--separator); }

/* ---------- Auth pages ---------- */
.auth-shell { max-width: 420px; margin: 64px auto; padding: 0 24px; }
.auth-card { background: var(--surface); border: 1px solid var(--separator); border-radius: var(--radius-lg); padding: 32px; box-shadow: var(--shadow-card); }
.auth-card h1 { font-size: 24px; margin: 0 0 6px; font-weight: 800; }
.auth-card p.sub { color: var(--label-secondary); margin: 0 0 26px; font-size: 14.5px; }

/* ---------- Utility ---------- */
.text-center { text-align: center; }
.mt-0 { margin-top: 0; }
.muted { color: var(--label-secondary); }
.page-header { padding: 40px 0 8px; }
.page-header h1 { font-size: 30px; font-weight: 800; letter-spacing: -0.6px; margin: 0 0 8px; }

/* ---------- Blog ---------- */
.blog-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); gap: 20px; }
.blog-card {
    background: var(--surface); border: 1px solid var(--separator); border-radius: var(--radius-lg);
    overflow: hidden; color: var(--label); display: flex; flex-direction: column;
    transition: box-shadow var(--transition), transform var(--transition);
}
.blog-card:hover { text-decoration: none; box-shadow: var(--shadow-card); transform: translateY(-2px); }
.blog-cover { width: 100%; height: 170px; object-fit: cover; background: var(--bg); }
.blog-cover-fallback { display: flex; align-items: center; justify-content: center; background: var(--hero-gradient); color: #fff; font-size: 30px; }
.blog-card-body { padding: 18px; }
.blog-meta { font-size: 12.5px; color: var(--label-secondary); font-weight: 600; margin-bottom: 6px; }
.blog-card-body h3 { font-size: 16.5px; font-weight: 800; margin: 0 0 8px; line-height: 1.35; }
.blog-card-body p { font-size: 13.5px; color: var(--label-secondary); margin: 0; }
.blog-content { font-size: 16.5px; line-height: 1.75; }
.blog-content p { margin: 0 0 20px; }
.blog-content p:last-child { margin-bottom: 0; }
