/* ==========================================================================
   VARIETY FUNERALS – CUSTOM CSS (Austin, Media Village)
   General CSS changes go in this file.

   Why: style.css is compiled from resources/sass, and that build is no longer
   used. Don't edit style.css or the Sass – add new styles here instead.
   This file loads after style.css (see functions.php), so rules here win
   without needing !important. Reuse existing theme classes where possible.

   Other custom files:
   - css/hero-form.css  (FD hero + Gravity Forms quote form)
   - css/boxes.css      (package boxes)
   - css/layout.css     (section spacing, e.g. .content-row.large)
   - css/typography.css (.balance utility, heading weights, list fixes)
   ========================================================================== */

/* PHONE LINK – text block link with a phone icon: <a class="phone-link" href="tel:...">  */
.phone-link { display: inline-flex; align-items: center; gap: 10px; font-size: 22px; font-weight: 700; color: #840047; }
.phone-link::before { content: "\f095"; font-family: 'FontAwesome'; font-weight: normal; color: #FABA05; }

/* LANDING PAGES (page-fd.php) ---------------------------------------------
   Same header as the Immediate Direct Cremation page (phone number, no menu)
   and no footer columns. Scoped to the FD template only. */
.page-template-page-fd header .header-right .widget > a { font-size: 20px !important; }  /* !important beats an inline #block-4 rule */
.page-template-page-fd header .header-right .widget > a small { font-size: 14px !important; }
.page-template-page-fd header .header-right .widget > a > i.fa-phone,   /* phone icon only, keeps the button arrow */
.page-template-page-fd header .header-right .main-navigation,
.page-template-page-fd #colophon { display: none !important; }

@media (max-width: 991px) {
    .page-template-page-fd .mobile-menu-button { display: none !important; }
    .page-template-page-fd .header-right > .widget > a:not(.vc_btn3) { display: flex; flex-direction: column; }   /* phone link only */
}
@media (max-width: 767px) {
    .page-template-page-fd .site-header { padding: 15px 10px !important; }
}
@media (max-width: 640px) {
    .page-template-page-fd #content { padding-top: 124px !important; }   /* landing page header is taller than the site's (110px) */
}
@media (max-width: 430px) {
    .page-template-page-fd header .header-right .widget > a { font-size: 18px !important; }
    .page-template-page-fd header .header-right .widget > a small { font-size: 12px !important; }
}

/* USP strip (landing pages) – reuses the theme's .usps row, styled to the FD design:
   desktop = full-width cells with dividers, icon left; mobile = 2x2 grid, icon on top.
   Sizes scale with the screen via clamp(). */
.page-template-page-fd .usps {
    padding: 0 16px !important;            /* overrides WP Bakery stretch-row inline padding: full width */
    font-size: clamp(14px, 1.18vw, 20px);   /* 20px on large desktops (~1700px+) */
    line-height: 1.25;
}
.page-template-page-fd .usps .vc_column-inner { padding-top: 0; }
@media (min-width: 993px) { .page-template-page-fd .usps .vc_column-inner > .wpb_wrapper { flex-wrap: nowrap; } }
@media (min-width: 1700px) { .page-template-page-fd .usps { white-space: nowrap; } }  /* one line each when there is room */
.page-template-page-fd .usps .wpb_text_column .wpb_wrapper > div { text-wrap: balance; }
.page-template-page-fd .usps .wpb_text_column { display: flex; align-items: center; justify-content: center; flex: 1 1 auto; margin: 0 !important;  /* centre content so logo + icon items line up */ padding: clamp(20px, 2vw, 30px) clamp(12px, 1.6vw, 28px); }
.page-template-page-fd .usps .wpb_text_column + .wpb_text_column { border-left: 1px solid #F0E7DC; }
.page-template-page-fd .usps .wpb_text_column .wpb_wrapper > div { gap: clamp(10px, 1vw, 16px); }
.page-template-page-fd .usps .wpb_text_column .wpb_wrapper > div img { flex-shrink: 0; margin: 0; width: auto; height: clamp(26px, 2.4vw, 36px); }
.page-template-page-fd .usps .wpb_text_column .wpb_wrapper > div img[src$=".svg"] {   /* round pink icon */
    box-sizing: content-box;
    width: clamp(18px, 1.6vw, 24px);
    height: clamp(18px, 1.6vw, 24px);
    padding: clamp(11px, 1vw, 14px);
    border-radius: 50%;
    background: #F7E8EF;
}
@media (max-width: 992px) {
    .page-template-page-fd .usps { padding: 0 !important; font-size: 15px; }
    .page-template-page-fd .usps .wpb_text_column { flex: 0 0 50%; width: 50%; padding: 24px 12px; }
    .page-template-page-fd .usps .wpb_text_column:nth-child(odd) { border-left: 0; }
    .page-template-page-fd .usps .wpb_text_column:nth-child(-n+2) { border-bottom: 1px solid #F0E7DC; }
    .page-template-page-fd .usps .wpb_text_column .wpb_wrapper > div { flex-direction: column; justify-content: center; text-align: center; gap: 12px; }
    .page-template-page-fd .usps .wpb_text_column .wpb_wrapper > div img { height: 30px; }
    .page-template-page-fd .usps .wpb_text_column .wpb_wrapper > div img[src$=".svg"] { width: 22px; height: 22px; padding: 12px; }
}

/* HOW IT WORKS ---------------------------------------------------------------
   WP Bakery: Row class "how-it-works content-row" > text block (H2)
   + inner row of 3 columns, each with one text block (H3 + paragraph).
   Step numbers and the connecting line are added by CSS. */
.how-it-works { counter-reset: hiw; text-align: center; }
.how-it-works h2 { margin-bottom: 48px; }
.how-it-works .vc_inner .vc_column_container { position: relative; counter-increment: hiw; }
.how-it-works .vc_inner .vc_column_container::before {   /* numbered circle */
    content: counter(hiw);
    display: flex;
    align-items: center;
    justify-content: center;
    width: 64px;
    height: 64px;
    margin: 0 auto 22px;
    border-radius: 50%;
    background: #840047;
    color: #fff;
    font-size: 28px;
    font-weight: 700;
}
.how-it-works .vc_inner .vc_column_container:not(:last-child)::after {   /* line to the next step */
    content: "";
    position: absolute;
    top: 31px;
    left: calc(50% + 48px);
    right: calc(-50% + 48px);
    height: 3px;
    background: #FABA05;
}
.how-it-works h3 { margin: 0 0 10px; font-size: 24px; color: #1E1A1C; }
.how-it-works .vc_inner p { max-width: 300px; margin: 0 auto; font-size: 18px; line-height: 1.5; }

@media (max-width: 767px) {   /* vertical list: number left, line runs down */
    .how-it-works { text-align: left; }
    .how-it-works h2 { margin-bottom: 32px; text-align: center; }
    .how-it-works .vc_inner .vc_column_container { padding-left: 72px; padding-bottom: 28px; }
    .how-it-works .vc_inner .vc_column_container::before { position: absolute; top: 0; left: 15px; width: 44px; height: 44px; margin: 0; font-size: 20px; }
    .how-it-works .vc_inner .vc_column_container:not(:last-child)::after { top: 52px; bottom: 8px; left: 36px; right: auto; width: 3px; height: auto; }
    .how-it-works .vc_inner .vc_column_container:last-child { padding-bottom: 0; }
    .how-it-works h3 { font-size: 21px; margin-bottom: 6px; }
    .how-it-works .vc_inner p { max-width: none; margin: 0; font-size: 17px; }
}

/* FAQS (theme .faqs row) ---------------------------------------------------- */
@media (min-width: 992px) {
    .faqs > .wpb_column:first-child > .vc_column-inner { padding-right: 100px; }   /* space between intro and questions */
}
.faqs .vc_tta-panel-heading a { padding-right: 70px !important; }   /* more room before the chevron (theme: 50px) */
.faqs .vc_tta-panel:first-child .vc_tta-panel-title > a { padding-top: 0 !important; }   /* first question lines up with the heading (theme sets 30px !important) */

/* BUTTON ARROWS (site-wide) ----------------------------------------------------
   The theme colours the arrow image with long CSS filter chains (invert/sepia/
   hue-rotate…). iOS Safari renders those differently, so arrows show pink/red.
   Instead, use the arrow as a mask filled with the button's text colour – it's
   then always the same colour as the button text, in every browser. */
.btn::after,
.ff-btn::after,
.nf-form-wrap .submit-wrap .ninja-forms-field::after {
    flex-shrink: 0;
    background: currentColor !important;
    -webkit-mask: url('../images/arrow-right-long-solid.svg') no-repeat center / contain;
    mask: url('../images/arrow-right-long-solid.svg') no-repeat center / contain;
    filter: none !important;
}

/* CALL BUTTON WITH 24/7 BADGE ----------------------------------------------------
   Add class "call-247" to a .btn, e.g. <a class="btn green call-247" href="tel:…">0800 774 7804</a>
   Shows a "24/7" pill before the number, in the button's text colour (same mask
   technique as the arrows, so it works in Safari and on any button colour). */
.btn.call-247::before {
    content: "";
    flex-shrink: 0;
    width: 2.6em;
    height: 1.22em;
    margin-right: 10px;
    background: currentColor;
    -webkit-mask: url('../images/icon-247.svg') no-repeat center / contain;
    mask: url('../images/icon-247.svg') no-repeat center / contain;
}

/* CREMATORIUM FINDER (GeoDirectory places) ----------------------------------
   Hide the place description (the fee paragraphs added by iDigit) on the
   listings and single crematorium pages. Text stays in the database. */
.geodir-field-post_content { display: none; }
