/* ================================================================
   Water Filter Finder – Stylesheet
   Mobile-first, conversion-focused, clean & modern.
   ================================================================ */

/* ── CUSTOM PROPERTIES ──────────────────────────────────────────── */
:root {
    --wff-primary       : #0ea5e9;   /* Sky blue  */
    --wff-primary-dark  : #0284c7;
    --wff-accent        : #06b6d4;
    --wff-wa-green      : #25D366;
    --wff-wa-green-dark : #1DA851;
    --wff-text          : #1e293b;
    --wff-text-muted    : #64748b;
    --wff-bg            : #f8fafc;
    --wff-white         : #ffffff;
    --wff-border        : #e2e8f0;
    --wff-shadow-sm     : 0 1px 3px rgba(0,0,0,.08), 0 1px 2px rgba(0,0,0,.04);
    --wff-shadow        : 0 4px 16px rgba(0,0,0,.08);
    --wff-shadow-lg     : 0 10px 40px rgba(0,0,0,.12);
    --wff-radius        : 16px;
    --wff-radius-sm     : 10px;
    --wff-transition    : 0.28s cubic-bezier(0.4, 0, 0.2, 1);
    --wff-font          : -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
}

/* ── WRAPPER ────────────────────────────────────────────────────── */
.wff-wrapper {
    font-family      : var(--wff-font);
    color            : var(--wff-text);
    background       : var(--wff-bg);
    border           : 1px solid var(--wff-border);
    border-radius    : var(--wff-radius);
    box-shadow       : var(--wff-shadow);
    padding          : 32px 24px;
    max-width        : 620px;
    margin           : 32px auto;
    box-sizing       : border-box;
    overflow         : hidden;
}

@media (min-width: 640px) {
    .wff-wrapper { padding: 48px 48px 40px; }
}

/* ── PROGRESS BAR ───────────────────────────────────────────────── */
.wff-progress-bar { margin-bottom: 36px; }

.wff-progress-track {
    height           : 6px;
    background       : var(--wff-border);
    border-radius    : 99px;
    overflow         : hidden;
}

.wff-progress-fill {
    height           : 100%;
    background       : linear-gradient(90deg, var(--wff-primary), var(--wff-accent));
    border-radius    : 99px;
    transition       : width 0.45s cubic-bezier(0.4, 0, 0.2, 1);
}

.wff-progress-label {
    font-size        : 13px;
    color            : var(--wff-text-muted);
    margin           : 8px 0 0;
    font-weight      : 500;
    letter-spacing   : 0.02em;
}

/* ── STEPS ──────────────────────────────────────────────────────── */
.wff-step {
    display          : none;
    opacity          : 0;
    transform        : translateX(30px);
}

.wff-step--active {
    display          : block;
    animation        : wff-stepIn 0.32s var(--wff-transition) forwards;
}

.wff-step--exit {
    display          : block;
    animation        : wff-stepOut 0.28s var(--wff-transition) forwards;
}

.wff-step--enter {
    transform        : translateX(30px);
    opacity          : 0;
}

@keyframes wff-stepIn {
    from { opacity: 0; transform: translateX(24px); }
    to   { opacity: 1; transform: translateX(0);    }
}

@keyframes wff-stepOut {
    from { opacity: 1; transform: translateX(0);     }
    to   { opacity: 0; transform: translateX(-24px); }
}

.wff-step__icon {
    font-size        : 3rem;
    text-align       : center;
    margin-bottom    : 12px;
    line-height      : 1;
}

.wff-step__question {
    font-size        : 1.35rem;
    font-weight      : 700;
    text-align       : center;
    color            : var(--wff-text);
    margin           : 0 0 28px;
    line-height      : 1.3;
}

@media (min-width: 640px) {
    .wff-step__question { font-size: 1.6rem; }
}

/* ── OPTION BUTTONS ─────────────────────────────────────────────── */
.wff-options {
    display          : flex;
    flex-wrap        : wrap;
    gap              : 14px;
    justify-content  : center;
}

.wff-option-btn {
    flex             : 1 1 140px;
    max-width        : 200px;
    display          : flex;
    flex-direction   : column;
    align-items      : center;
    gap              : 10px;
    padding          : 22px 16px 18px;
    background       : var(--wff-white);
    border           : 2px solid var(--wff-border);
    border-radius    : var(--wff-radius);
    cursor           : pointer;
    transition       : border-color var(--wff-transition),
                       box-shadow   var(--wff-transition),
                       transform    var(--wff-transition),
                       background   var(--wff-transition);
    font-family      : var(--wff-font);
    box-shadow       : var(--wff-shadow-sm);
}

.wff-option-btn:hover,
.wff-option-btn:focus-visible {
    border-color     : var(--wff-primary);
    box-shadow       : 0 0 0 3px rgba(14, 165, 233, 0.15), var(--wff-shadow);
    transform        : translateY(-2px);
    outline          : none;
}

.wff-option-btn--selected {
    border-color     : var(--wff-primary);
    background       : linear-gradient(135deg, #e0f2fe 0%, #f0fdf4 100%);
    box-shadow       : 0 0 0 3px rgba(14, 165, 233, 0.2), var(--wff-shadow);
    transform        : scale(1.02);
}

.wff-option-icon {
    font-size        : 2.4rem;
    line-height      : 1;
}

.wff-option-text {
    font-size        : 1rem;
    font-weight      : 600;
    color            : var(--wff-text);
    text-align       : center;
}

/* ── RESULT PANEL ───────────────────────────────────────────────── */
.wff-result { display: none; }

.wff-result--visible {
    display    : block;
    animation  : wff-fadeUp 0.4s cubic-bezier(0.4,0,0.2,1) forwards;
}

@keyframes wff-fadeUp {
    from { opacity: 0; transform: translateY(20px); }
    to   { opacity: 1; transform: translateY(0);    }
}

.wff-result__inner { /* container */ }

/* Badge */
.wff-badge {
    display          : inline-block;
    background       : linear-gradient(90deg, var(--wff-primary), var(--wff-accent));
    color            : var(--wff-white);
    font-size        : 12px;
    font-weight      : 700;
    letter-spacing   : 0.05em;
    text-transform   : uppercase;
    padding          : 5px 14px;
    border-radius    : 99px;
    margin-bottom    : 16px;
}

.wff-result__title {
    font-size        : 1.5rem;
    font-weight      : 800;
    color            : var(--wff-text);
    margin           : 0 0 24px;
    line-height      : 1.2;
}

@media (min-width: 640px) {
    .wff-result__title { font-size: 1.75rem; }
}

/* Answer Summary */
.wff-result__summary-wrap {
    background       : var(--wff-white);
    border           : 1px solid var(--wff-border);
    border-radius    : var(--wff-radius-sm);
    padding          : 16px 20px;
    margin-bottom    : 24px;
}

.wff-result__summary-heading {
    font-size        : 12px;
    font-weight      : 700;
    text-transform   : uppercase;
    letter-spacing   : 0.06em;
    color            : var(--wff-text-muted);
    margin           : 0 0 10px;
}

.wff-summary {
    list-style       : none;
    margin           : 0;
    padding          : 0;
    display          : flex;
    flex-wrap        : wrap;
    gap              : 8px 24px;
}

.wff-summary li {
    font-size        : 14px;
}

.wff-summary__label {
    color            : var(--wff-text-muted);
    margin-right     : 4px;
}

.wff-summary__value {
    font-weight      : 600;
    color            : var(--wff-text);
}

/* Products */
.wff-result__products-heading {
    font-size        : 14px;
    font-weight      : 700;
    color            : var(--wff-text-muted);
    text-transform   : uppercase;
    letter-spacing   : 0.06em;
    margin           : 0 0 12px;
}

.wff-product-card {
    display          : flex;
    align-items      : flex-start;
    gap              : 14px;
    padding          : 16px 18px;
    border-radius    : var(--wff-radius-sm);
    margin-bottom    : 10px;
    border           : 1px solid transparent;
    transition       : box-shadow var(--wff-transition);
}

.wff-product-card--primary {
    background       : linear-gradient(135deg, #e0f2fe 0%, #ecfdf5 100%);
    border-color     : #bae6fd;
}

.wff-product-card--secondary {
    background       : var(--wff-white);
    border-color     : var(--wff-border);
}

.wff-product-card:hover { box-shadow: var(--wff-shadow); }

.wff-product-card__icon {
    font-size        : 1.8rem;
    line-height      : 1;
    flex-shrink      : 0;
    margin-top       : 2px;
}

.wff-product-card__name {
    font-size        : 1rem;
    font-weight      : 700;
    color            : var(--wff-text);
    margin           : 0 0 4px;
}

.wff-product-card__desc {
    font-size        : 14px;
    color            : var(--wff-text-muted);
    margin           : 0;
    line-height      : 1.5;
}

/* Notes */
.wff-result__notes { margin: 20px 0; }

.wff-note {
    padding          : 14px 18px;
    border-radius    : var(--wff-radius-sm);
    font-size        : 14px;
    line-height      : 1.6;
    margin-bottom    : 10px;
}

.wff-note--capacity {
    background       : #fefce8;
    border           : 1px solid #fde68a;
    color            : #78350f;
}

.wff-note--install {
    background       : #f0fdf4;
    border           : 1px solid #86efac;
    color            : #14532d;
}

/* ── CTA SECTION ────────────────────────────────────────────────── */
.wff-cta {
    margin           : 32px 0 20px;
    border-radius    : var(--wff-radius);
    overflow         : hidden;
    box-shadow       : var(--wff-shadow-lg);
}

.wff-cta__inner {
    background       : linear-gradient(135deg, #0f172a 0%, #1e293b 100%);
    padding          : 32px 28px 36px;
    text-align       : center;
    position         : relative;
}

/* Decorative circles */
.wff-cta__inner::before,
.wff-cta__inner::after {
    content          : '';
    position         : absolute;
    border-radius    : 50%;
    background       : rgba(255,255,255,0.03);
    pointer-events   : none;
}
.wff-cta__inner::before {
    width: 260px; height: 260px;
    top: -80px; right: -80px;
}
.wff-cta__inner::after {
    width: 180px; height: 180px;
    bottom: -60px; left: -60px;
}

.wff-cta__icon {
    font-size        : 2.8rem;
    margin-bottom    : 10px;
    filter           : drop-shadow(0 2px 8px rgba(0,0,0,.3));
}

.wff-cta__headline {
    font-size        : 1.3rem;
    font-weight      : 800;
    color            : var(--wff-white);
    margin           : 0 0 10px;
    line-height      : 1.3;
}

@media (min-width: 640px) {
    .wff-cta__headline { font-size: 1.5rem; }
}

.wff-cta__sub {
    font-size        : 14px;
    color            : rgba(255,255,255,0.65);
    margin           : 0 0 24px;
    line-height      : 1.6;
}

/* WhatsApp Button */
.wff-cta__btn {
    display          : inline-flex;
    align-items      : center;
    justify-content  : center;
    gap              : 10px;
    background       : var(--wff-wa-green);
    color            : var(--wff-white);
    font-size        : 1rem;
    font-weight      : 700;
    font-family      : var(--wff-font);
    text-decoration  : none;
    padding          : 16px 30px;
    border-radius    : 12px;
    box-shadow       : 0 4px 20px rgba(37, 211, 102, 0.4);
    transition       : background var(--wff-transition),
                       box-shadow  var(--wff-transition),
                       transform   var(--wff-transition);
    width            : 100%;
    max-width        : 380px;
    letter-spacing   : 0.01em;
    position         : relative;
    z-index          : 1;
}

.wff-cta__btn:hover,
.wff-cta__btn:focus-visible {
    background       : var(--wff-wa-green-dark);
    box-shadow       : 0 6px 28px rgba(37, 211, 102, 0.55);
    transform        : translateY(-2px);
    color            : var(--wff-white);
    text-decoration  : none;
    outline          : none;
}

.wff-cta__btn:active {
    transform        : translateY(0);
}

.wff-cta__wa-icon {
    width            : 22px;
    height           : 22px;
    flex-shrink      : 0;
}

/* Pulse animation for WA button */
@keyframes wff-pulse {
    0%   { box-shadow: 0 4px 20px rgba(37,211,102,0.4); }
    50%  { box-shadow: 0 4px 32px rgba(37,211,102,0.7); }
    100% { box-shadow: 0 4px 20px rgba(37,211,102,0.4); }
}

.wff-cta__btn { animation: wff-pulse 2.6s ease-in-out infinite; }
.wff-cta__btn:hover { animation: none; }

/* ── RESTART BUTTON ─────────────────────────────────────────────── */
.wff-restart-wrap {
    text-align       : center;
    margin-top       : 20px;
}

.wff-restart-btn {
    background       : transparent;
    border           : none;
    color            : var(--wff-text-muted);
    font-size        : 14px;
    font-family      : var(--wff-font);
    cursor           : pointer;
    padding          : 6px 10px;
    border-radius    : 6px;
    transition       : color var(--wff-transition), background var(--wff-transition);
}

.wff-restart-btn:hover {
    color            : var(--wff-primary);
    background       : rgba(14,165,233,0.07);
}

/* ── ADMIN ENHANCEMENTS (optional, lives on wp-admin) ───────────── */
/* No admin styles needed – using WP defaults */
