/* ==========================================================================
   ReviewsWidgets — Main Stylesheet
   Polar / Black & White / Modern Minimal
   ========================================================================== */

/* Reset & base ----------------------------------------------------------- */
*, *::before, *::after { box-sizing: border-box; }

:root {
    --bg: #ffffff;
    --bg-soft: #fafafa;
    --bg-tint: #f5f5f5;
    --ink: #0a0a0a;
    --ink-soft: #404040;
    --ink-muted: #737373;
    --line: #e5e5e5;
    --line-strong: #d4d4d4;
    --accent: #000000;
    --accent-ink: #ffffff;
    --gold: #fbbc04;          /* Google star color */
    --green: #34a853;
    --danger: #d93025;
    --radius: 12px;
    --radius-sm: 8px;
    --radius-lg: 18px;
    --shadow-sm: 0 1px 2px rgba(0,0,0,.04), 0 1px 3px rgba(0,0,0,.06);
    --shadow:    0 2px 4px rgba(0,0,0,.04), 0 8px 24px rgba(0,0,0,.06);
    --shadow-lg: 0 4px 8px rgba(0,0,0,.04), 0 24px 48px rgba(0,0,0,.08);
    --container: 1180px;
    --font: 'Inter', -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Oxygen, Ubuntu, Cantarell, "Helvetica Neue", Arial, sans-serif;
}

html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
body {
    margin: 0;
    font-family: var(--font);
    color: var(--ink);
    background: var(--bg);
    line-height: 1.6;
    font-size: 16px;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

img, svg { max-width: 100%; display: block; }
a { color: var(--ink); text-decoration: none; transition: opacity .15s ease; }
a:hover { opacity: .7; }

h1, h2, h3, h4, h5, h6 {
    font-weight: 700;
    line-height: 1.2;
    letter-spacing: -.02em;
    margin: 0 0 .5em;
    color: var(--ink);
}
h1 { font-size: clamp(2rem, 5vw, 3.25rem); font-weight: 800; letter-spacing: -.035em; }
h2 { font-size: clamp(1.5rem, 3.5vw, 2.25rem); }
h3 { font-size: 1.25rem; }
p  { margin: 0 0 1em; color: var(--ink-soft); }

button { font-family: inherit; cursor: pointer; }
input, select, textarea { font-family: inherit; font-size: inherit; }

.skip-link {
    position: absolute; left: -9999px; top: 0;
    background: var(--ink); color: var(--accent-ink);
    padding: .75rem 1rem; z-index: 100; border-radius: 0 0 var(--radius-sm) 0;
}
.skip-link:focus { left: 0; }

.container { width: 100%; max-width: var(--container); margin: 0 auto; padding: 0 1.25rem; }

/* Header ----------------------------------------------------------------- */
.site-header {
    position: sticky; top: 0; z-index: 50;
    background: rgba(255,255,255,.85);
    backdrop-filter: saturate(180%) blur(14px);
    -webkit-backdrop-filter: saturate(180%) blur(14px);
    border-bottom: 1px solid var(--line);
}
.header-inner {
    display: flex; align-items: center; justify-content: space-between;
    height: 64px;
}
.logo {
    display: inline-flex; align-items: center; gap: .55rem;
    font-weight: 800; font-size: 1.1rem; letter-spacing: -.02em;
}
.logo:hover { opacity: 1; }
.logo-mark { display: inline-flex; }

.site-nav .nav-list {
    list-style: none; margin: 0; padding: 0;
    display: flex; gap: .25rem;
}
.site-nav .nav-list a {
    display: inline-block;
    padding: .55rem .9rem;
    border-radius: var(--radius-sm);
    font-size: .94rem; font-weight: 500;
    color: var(--ink-soft);
}
.site-nav .nav-list a:hover { background: var(--bg-tint); color: var(--ink); opacity: 1; }

.nav-toggle {
    display: none;
    background: transparent; border: 1px solid var(--line);
    width: 40px; height: 40px; border-radius: var(--radius-sm);
    padding: 0; align-items: center; justify-content: center;
    flex-direction: column; gap: 4px;
}
.nav-toggle span {
    display: block; width: 18px; height: 2px; background: var(--ink); border-radius: 2px;
}

@media (max-width: 720px) {
    .nav-toggle { display: inline-flex; }
    .nav-list {
        position: absolute; top: 64px; right: 0; left: 0;
        background: #fff; border-bottom: 1px solid var(--line);
        flex-direction: column; gap: 0;
        padding: .5rem 1rem 1rem;
        display: none;
    }
    .nav-list.is-open { display: flex; }
    .nav-list li { width: 100%; }
    .nav-list a { display: block; padding: .85rem .75rem; }
}

/* Buttons ---------------------------------------------------------------- */
.btn {
    display: inline-flex; align-items: center; justify-content: center;
    gap: .5rem;
    padding: .85rem 1.4rem;
    font-size: .95rem; font-weight: 600;
    border-radius: var(--radius-sm);
    border: 1px solid transparent;
    text-decoration: none; cursor: pointer;
    transition: transform .15s ease, background .15s ease, border-color .15s ease;
    line-height: 1;
}
.btn:hover { opacity: 1; transform: translateY(-1px); }
.btn-primary { background: var(--ink); color: var(--accent-ink); }
.btn-primary:hover { background: #1f1f1f; }
.btn-secondary { background: #fff; color: var(--ink); border-color: var(--line-strong); }
.btn-secondary:hover { background: var(--bg-tint); }
.btn-ghost { background: transparent; color: var(--ink); }
.btn-ghost:hover { background: var(--bg-tint); }
.btn-lg { padding: 1rem 1.6rem; font-size: 1rem; }
.btn-sm { padding: .55rem .9rem; font-size: .85rem; }

/* Hero ------------------------------------------------------------------- */
.hero {
    padding: clamp(3rem, 8vw, 5.5rem) 0 clamp(2rem, 5vw, 3rem);
    text-align: center;
    background:
        radial-gradient(ellipse 60% 60% at 50% 0%, rgba(0,0,0,.05), transparent 70%),
        var(--bg);
}
.eyebrow {
    display: inline-flex; align-items: center; gap: .4rem;
    font-size: .8rem; font-weight: 600;
    letter-spacing: .04em; text-transform: uppercase;
    color: var(--ink-muted);
    background: var(--bg-tint);
    padding: .4rem .8rem;
    border-radius: 999px;
    margin-bottom: 1.5rem;
    border: 1px solid var(--line);
}
.eyebrow .dot { width: 6px; height: 6px; background: var(--green); border-radius: 50%; }

.hero h1 { max-width: 22ch; margin-left: auto; margin-right: auto; }
.hero .lead {
    max-width: 56ch; margin: 1rem auto 0;
    font-size: clamp(1rem, 1.6vw, 1.15rem);
    color: var(--ink-muted);
}
.hero-meta {
    display: flex; flex-wrap: wrap; gap: 1.5rem; justify-content: center;
    margin-top: 2rem; font-size: .9rem; color: var(--ink-muted);
}
.hero-meta span { display: inline-flex; align-items: center; gap: .4rem; }
.hero-meta .check { color: var(--green); font-weight: 700; }

/* Generator card --------------------------------------------------------- */
.generator {
    margin-top: 2.5rem;
    background: #fff;
    border: 1px solid var(--line);
    border-radius: var(--radius-lg);
    padding: clamp(1.25rem, 3vw, 2rem);
    box-shadow: var(--shadow);
}
.generator h2 {
    font-size: 1.1rem; margin-bottom: 1rem;
    text-align: left;
}

.field { margin-bottom: 1rem; }
.field label {
    display: block; font-size: .85rem; font-weight: 600;
    color: var(--ink); margin-bottom: .4rem;
}
.field .hint { display: block; font-size: .8rem; color: var(--ink-muted); margin-top: .35rem; }

.input,
.select {
    width: 100%;
    padding: .85rem 1rem;
    border: 1px solid var(--line-strong);
    border-radius: var(--radius-sm);
    background: #fff;
    color: var(--ink);
    transition: border-color .15s ease, box-shadow .15s ease;
}
.input:focus, .select:focus {
    outline: none;
    border-color: var(--ink);
    box-shadow: 0 0 0 3px rgba(0,0,0,.08);
}

.checkbox-row {
    display: flex; align-items: flex-start; gap: .65rem;
    padding: .85rem 1rem;
    background: var(--bg-soft);
    border: 1px solid var(--line);
    border-radius: var(--radius-sm);
}
.checkbox-row input[type="checkbox"] {
    margin-top: 3px; width: 18px; height: 18px; accent-color: var(--ink);
    flex-shrink: 0;
}
.checkbox-row label { font-size: .9rem; color: var(--ink); margin: 0; cursor: pointer; }
.checkbox-row .pro-tag {
    display: inline-block; font-size: .7rem; font-weight: 700;
    background: var(--ink); color: #fff;
    padding: 2px 7px; border-radius: 4px; margin-left: 6px;
    vertical-align: middle;
}

.generator-actions {
    display: flex; gap: .75rem; flex-wrap: wrap; margin-top: 1.25rem;
}

.status-msg {
    margin-top: 1rem; padding: .75rem 1rem;
    border-radius: var(--radius-sm);
    font-size: .9rem;
    display: none;
}
.status-msg.is-loading { display: block; background: var(--bg-tint); color: var(--ink-soft); }
.status-msg.is-error   { display: block; background: #fef2f2; color: var(--danger); border: 1px solid #fecaca; }
.status-msg.is-success { display: block; background: #f0fdf4; color: #166534; border: 1px solid #bbf7d0; }

/* Templates section ------------------------------------------------------ */
.section { padding: clamp(2.5rem, 6vw, 4rem) 0; }
.section-head { text-align: center; margin-bottom: 2.5rem; }
.section-head h2 { margin-bottom: .5rem; }
.section-head p  { color: var(--ink-muted); max-width: 60ch; margin: 0 auto; }

.template-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 1.25rem;
}
.template-card {
    background: #fff;
    border: 2px solid var(--line);
    border-radius: var(--radius);
    padding: 1.25rem;
    cursor: pointer;
    transition: border-color .15s ease, transform .15s ease, box-shadow .15s ease;
    position: relative;
}
.template-card:hover { border-color: var(--ink); transform: translateY(-2px); box-shadow: var(--shadow); }
.template-card.is-selected { border-color: var(--ink); box-shadow: 0 0 0 3px rgba(0,0,0,.08); }
.template-card.is-selected::after {
    content: "✓"; position: absolute; top: 12px; right: 12px;
    width: 24px; height: 24px; border-radius: 50%;
    background: var(--ink); color: #fff;
    display: flex; align-items: center; justify-content: center;
    font-size: 14px; font-weight: 700;
}
.template-card h3 { font-size: 1rem; margin: 1rem 0 .25rem; }
.template-card p  { font-size: .85rem; color: var(--ink-muted); margin: 0; }
.template-preview {
    background: var(--bg-soft);
    border: 1px solid var(--line);
    border-radius: var(--radius-sm);
    padding: 1rem;
    min-height: 180px;
    overflow: hidden;
}

/* Live preview & embed --------------------------------------------------- */
.preview-wrap {
    margin-top: 2rem;
    background: var(--bg-soft);
    border: 1px solid var(--line);
    border-radius: var(--radius-lg);
    padding: clamp(1rem, 2.5vw, 1.5rem);
    display: none;
}
.preview-wrap.is-active { display: block; }
.preview-head {
    display: flex; align-items: center; justify-content: space-between;
    flex-wrap: wrap; gap: 1rem; margin-bottom: 1rem;
}
.preview-head h3 { margin: 0; font-size: 1rem; }

#widgetPreview {
    background: #fff;
    border-radius: var(--radius);
    padding: 1.5rem;
    border: 1px solid var(--line);
    min-height: 200px;
}

.embed-block {
    margin-top: 1.25rem;
}
.embed-block h4 { font-size: .9rem; margin: 0 0 .5rem; color: var(--ink); }
.embed-code {
    background: #0a0a0a; color: #e5e5e5;
    border-radius: var(--radius-sm);
    padding: 1rem;
    font-family: 'SF Mono', Menlo, Consolas, Monaco, monospace;
    font-size: .82rem; line-height: 1.5;
    overflow-x: auto;
    white-space: pre;
    position: relative;
}
.copy-btn {
    position: absolute; top: 8px; right: 8px;
    background: rgba(255,255,255,.1); color: #fff;
    border: 1px solid rgba(255,255,255,.2);
    padding: .4rem .7rem; font-size: .75rem; font-weight: 600;
    border-radius: 6px; cursor: pointer;
}
.copy-btn:hover { background: rgba(255,255,255,.2); }
.copy-btn.copied { background: var(--green); border-color: var(--green); }

/* Features --------------------------------------------------------------- */
.features { background: var(--bg-soft); }
.feature-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
    gap: 1.5rem;
}
.feature {
    background: #fff;
    border: 1px solid var(--line);
    border-radius: var(--radius);
    padding: 1.5rem;
}
.feature .icon {
    width: 40px; height: 40px;
    background: var(--ink); color: #fff;
    border-radius: 10px;
    display: flex; align-items: center; justify-content: center;
    font-size: 18px; margin-bottom: 1rem;
}
.feature h3 { font-size: 1rem; margin: 0 0 .35rem; }
.feature p  { font-size: .9rem; margin: 0; }

/* FAQ -------------------------------------------------------------------- */
.faq { max-width: 760px; margin: 0 auto; }
.faq details {
    border-bottom: 1px solid var(--line);
    padding: 1.1rem 0;
}
.faq summary {
    font-weight: 600; cursor: pointer;
    list-style: none; display: flex; justify-content: space-between; align-items: center;
    color: var(--ink); font-size: 1rem;
}
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after { content: "+"; font-size: 1.4rem; font-weight: 400; color: var(--ink-muted); transition: transform .2s; }
.faq details[open] summary::after { content: "−"; }
.faq details p { margin: .75rem 0 0; color: var(--ink-soft); font-size: .95rem; }

/* Pricing ---------------------------------------------------------------- */
.pricing-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 1.5rem;
    max-width: 760px; margin: 0 auto;
}
.price-card {
    background: #fff;
    border: 2px solid var(--line);
    border-radius: var(--radius-lg);
    padding: 2rem;
    position: relative;
    display: flex; flex-direction: column;
}
.price-card.is-featured { border-color: var(--ink); box-shadow: var(--shadow-lg); }
.price-card .badge {
    position: absolute; top: -12px; right: 1.5rem;
    background: var(--ink); color: #fff;
    padding: .25rem .75rem; font-size: .75rem; font-weight: 700;
    border-radius: 999px; letter-spacing: .03em;
}
.price-card h3 { font-size: 1.2rem; margin: 0; }
.price-card .price {
    font-size: 2.5rem; font-weight: 800; letter-spacing: -.03em;
    margin: 1rem 0 .25rem; color: var(--ink);
}
.price-card .price small { font-size: 1rem; color: var(--ink-muted); font-weight: 500; }
.price-card .price-sub { font-size: .9rem; color: var(--ink-muted); margin-bottom: 1.5rem; }
.price-card ul {
    list-style: none; padding: 0; margin: 0 0 1.5rem;
    display: flex; flex-direction: column; gap: .65rem; flex: 1;
}
.price-card li { font-size: .92rem; color: var(--ink-soft); display: flex; gap: .5rem; align-items: flex-start; }
.price-card li::before {
    content: "✓"; color: var(--green); font-weight: 700; flex-shrink: 0;
}
.price-card .btn { width: 100%; }

.trust-note {
    max-width: 760px; margin: 2rem auto 0;
    background: var(--bg-soft); border: 1px solid var(--line);
    border-radius: var(--radius); padding: 1.25rem 1.5rem;
    font-size: .9rem; color: var(--ink-soft);
    text-align: center;
}

/* Generic content pages -------------------------------------------------- */
.page-hero {
    padding: clamp(3rem, 6vw, 4.5rem) 0 clamp(1.5rem, 3vw, 2rem);
    text-align: center;
}
.page-content {
    max-width: 720px; margin: 0 auto;
    padding: 0 1.25rem 4rem;
}
.page-content h2 { margin-top: 2.5rem; font-size: 1.5rem; }
.page-content h3 { margin-top: 1.75rem; font-size: 1.15rem; }
.page-content ul, .page-content ol { padding-left: 1.25rem; }
.page-content li { margin: .35rem 0; color: var(--ink-soft); }
.page-content a { text-decoration: underline; }

/* Contact form ----------------------------------------------------------- */
.contact-form {
    max-width: 540px; margin: 0 auto;
    background: #fff; border: 1px solid var(--line);
    border-radius: var(--radius-lg); padding: 2rem;
}
.contact-form .field textarea.input { min-height: 140px; resize: vertical; font-family: inherit; }

/* Ad slots --------------------------------------------------------------- */
.ad-slot {
    margin: 2rem auto;
    background: var(--bg-soft);
    border: 1px dashed var(--line-strong);
    border-radius: var(--radius-sm);
    color: var(--ink-muted);
    font-size: .8rem;
    text-align: center;
    padding: 1rem;
    min-height: 90px;
    display: flex; align-items: center; justify-content: center;
}

/* Footer ----------------------------------------------------------------- */
.site-footer {
    background: #0a0a0a;
    color: #a3a3a3;
    padding: 3.5rem 0 1.5rem;
    margin-top: 3rem;
}
.site-footer a { color: #d4d4d4; }
.site-footer a:hover { color: #fff; opacity: 1; }
.site-footer .logo { color: #fff; }

.footer-grid {
    display: grid;
    grid-template-columns: 1.5fr repeat(3, 1fr);
    gap: 2.5rem;
    margin-bottom: 2.5rem;
}
@media (max-width: 720px) {
    .footer-grid { grid-template-columns: 1fr 1fr; gap: 1.75rem; }
    .footer-brand { grid-column: 1 / -1; }
}
.footer-col h4 {
    color: #fff; font-size: .85rem; font-weight: 600;
    text-transform: uppercase; letter-spacing: .05em;
    margin: 0 0 1rem;
}
.footer-col ul { list-style: none; padding: 0; margin: 0; display: flex; flex-direction: column; gap: .5rem; }
.footer-col a { font-size: .9rem; }
.footer-tagline { font-size: .9rem; color: #a3a3a3; margin: 1rem 0 0; max-width: 32ch; }

.footer-bottom {
    border-top: 1px solid #262626;
    padding-top: 1.5rem;
    display: flex; justify-content: space-between; align-items: center;
    flex-wrap: wrap; gap: 1rem;
    font-size: .85rem;
}
.footer-bottom p { margin: 0; color: #737373; }
.footer-credit a { color: #fff; font-weight: 600; }
.footer-credit a:hover { text-decoration: underline; }

/* Utilities -------------------------------------------------------------- */
.text-center { text-align: center; }
.mt-2 { margin-top: 2rem; }
.hidden { display: none !important; }

/* Google Places autocomplete dropdown styling override */
.pac-container {
    border-radius: var(--radius-sm) !important;
    box-shadow: var(--shadow-lg) !important;
    border: 1px solid var(--line) !important;
    margin-top: 4px !important;
    font-family: var(--font) !important;
}
.pac-item { padding: .5rem .75rem !important; cursor: pointer; }
.pac-item-query { font-weight: 600; }
