:root {
    --arth-primary: #183030;
    --arth-primary-soft: #284a46;
    --arth-accent: #c9a56b;
    --arth-bg: #f5f6f3;
    --arth-surface: #ffffff;
    --arth-text: #152421;
    --arth-muted: #66736f;
    --arth-border: #dde4e1;
    --arth-shadow: 0 18px 50px rgba(24, 48, 48, 0.09);
    --arth-radius: 20px;
}

.arth-fc-directory,
.arth-fc-single {
    width: 100%;
    max-width: 1240px;
    margin: 0 auto;
    color: var(--arth-text);
    font-family: inherit;
    box-sizing: border-box;
}

.arth-fc-directory *,
.arth-fc-single * {
    box-sizing: border-box;
}

.arth-fc-directory__hero {
    padding: 44px 34px;
    border: 1px solid var(--arth-border);
    border-radius: 28px;
    background:
        radial-gradient(circle at 90% 15%, rgba(201, 165, 107, 0.22), transparent 28%),
        linear-gradient(135deg, #f8faf7 0%, #eef2ee 100%);
    margin-bottom: 30px;
    overflow: hidden;
}

.arth-fc-directory__hero h1,
.arth-fc-single__header h1 {
    margin: 5px 0 10px;
    color: var(--arth-primary);
    font-size: clamp(32px, 4vw, 54px);
    line-height: 1.08;
    letter-spacing: -0.035em;
}

.arth-fc-directory__hero p,
.arth-fc-single__header p {
    max-width: 760px;
    margin: 0;
    color: var(--arth-muted);
    font-size: 17px;
    line-height: 1.7;
}

.arth-fc-eyebrow {
    display: inline-block;
    color: var(--arth-primary-soft);
    font-size: 12px;
    font-weight: 800;
    letter-spacing: 0.14em;
}

.arth-fc-toolbar {
    display: grid;
    grid-template-columns: minmax(260px, 320px) minmax(0, 1fr);
    gap: 16px;
    align-items: start;
    margin-bottom: 28px;
    overflow: visible;
}

.arth-fc-search {
    position: relative;
    display: block;
}

.arth-fc-search svg {
    position: absolute;
    left: 17px;
    top: 50%;
    width: 20px;
    transform: translateY(-50%);
    fill: none;
    stroke: var(--arth-muted);
    stroke-width: 2;
    stroke-linecap: round;
}

.arth-fc-search input {
    width: 100%;
    min-height: 52px;
    padding: 12px 16px 12px 48px;
    border: 1px solid var(--arth-border);
    border-radius: 15px;
    background: #fff;
    color: var(--arth-text);
    font: inherit;
    outline: none;
    transition: border-color .2s ease, box-shadow .2s ease;
}

.arth-fc-search input:focus {
    border-color: var(--arth-primary-soft);
    box-shadow: 0 0 0 4px rgba(24, 48, 48, 0.08);
}

.arth-fc-filters {
    display: flex;
    min-width: 0;
    gap: 9px;
    align-items: center;
    justify-content: flex-start;
    flex-wrap: wrap;
    overflow: visible;
    padding: 0;
}

.arth-fc-filters button {
    min-height: 44px;
    padding: 9px 15px;
    flex: 0 0 auto;
    border: 1px solid var(--arth-border);
    border-radius: 999px;
    background: #fff;
    color: var(--arth-primary);
    font: inherit;
    font-size: 14px;
    font-weight: 700;
    white-space: nowrap;
    cursor: pointer;
    transition: .2s ease;
}

.arth-fc-filters button:hover,
.arth-fc-filters button.is-active {
    border-color: var(--arth-primary);
    background: var(--arth-primary);
    color: #fff;
}

.arth-fc-grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 20px;
}

.arth-fc-card {
    display: flex;
    min-height: 285px;
    padding: 24px;
    flex-direction: column;
    border: 1px solid var(--arth-border);
    border-radius: var(--arth-radius);
    background: var(--arth-surface);
    box-shadow: 0 10px 32px rgba(24, 48, 48, 0.055);
    transition: transform .25s ease, box-shadow .25s ease, border-color .25s ease;
}

.arth-fc-card:hover {
    transform: translateY(-5px);
    border-color: rgba(24, 48, 48, 0.35);
    box-shadow: var(--arth-shadow);
}

.arth-fc-card[hidden] {
    display: none;
}

.arth-fc-card__top {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 25px;
}

.arth-fc-card__icon,
.arth-fc-single__icon {
    display: inline-flex;
    width: 58px;
    height: 58px;
    align-items: center;
    justify-content: center;
    border-radius: 16px;
    background: #e7efec;
    color: var(--arth-primary);
    font-size: 15px;
    font-weight: 900;
    letter-spacing: -0.02em;
}

.arth-fc-card__icon--investment { background: #e0f2e8; color: #17613d; }
.arth-fc-card__icon--goal-planning { background: #eee7fa; color: #67429c; }
.arth-fc-card__icon--general { background: #fff0d9; color: #9b5b08; }
.arth-fc-card__icon--loans { background: #e4edf9; color: #285b91; }
.arth-fc-card__icon--savings { background: #e6f4f2; color: #17665f; }
.arth-fc-card__icon--tax { background: #e8eef0; color: #49656e; }
.arth-fc-card__icon--insurance { background: #f7e9df; color: #95552b; }
.arth-fc-card__icon--government-savings { background: #ececf8; color: #5259a2; }

.arth-fc-card__category {
    color: var(--arth-muted);
    font-size: 12px;
    font-weight: 800;
    letter-spacing: .06em;
    text-transform: uppercase;
}

.arth-fc-card h2 {
    margin: 0 0 10px;
    color: var(--arth-primary);
    font-size: 22px;
    line-height: 1.25;
}

.arth-fc-card p {
    margin: 0 0 25px;
    color: var(--arth-muted);
    font-size: 15px;
    line-height: 1.65;
}

.arth-fc-card__link {
    display: inline-flex;
    align-items: center;
    gap: 9px;
    margin-top: auto;
    color: var(--arth-primary);
    font-size: 15px;
    font-weight: 800;
    text-decoration: none !important;
}

.arth-fc-card__link span {
    transition: transform .2s ease;
}

.arth-fc-card__link:hover span {
    transform: translateX(4px);
}

.arth-fc-empty {
    padding: 45px;
    text-align: center;
    color: var(--arth-muted);
    border: 1px dashed var(--arth-border);
    border-radius: var(--arth-radius);
}

.arth-fc-back {
    display: inline-flex;
    margin-bottom: 22px;
    color: var(--arth-primary);
    font-weight: 750;
    text-decoration: none !important;
}

.arth-fc-single__header {
    display: flex;
    gap: 22px;
    align-items: flex-start;
    margin-bottom: 28px;
}

.arth-fc-single__header h1 {
    font-size: clamp(32px, 4vw, 48px);
}

.arth-fc-single__icon {
    flex: 0 0 70px;
    width: 70px;
    height: 70px;
    border-radius: 20px;
    font-size: 17px;
}

.arth-fc-calculator-shell {
    display: grid;
    grid-template-columns: minmax(0, 0.92fr) minmax(0, 1.08fr);
    gap: 24px;
    align-items: stretch;
}

.arth-fc-form,
.arth-fc-results {
    padding: 28px;
    border: 1px solid var(--arth-border);
    border-radius: 24px;
    background: #fff;
    box-shadow: 0 14px 42px rgba(24, 48, 48, 0.07);
}

.arth-fc-form__heading,
.arth-fc-results__heading {
    margin-bottom: 25px;
}

.arth-fc-form__heading h2,
.arth-fc-results__heading h2,
.arth-fc-related__heading h2 {
    margin: 0 0 6px;
    color: var(--arth-primary);
    font-size: 25px;
    line-height: 1.25;
}

.arth-fc-form__heading p {
    margin: 0;
    color: var(--arth-muted);
    font-size: 14px;
}

.arth-fc-field {
    margin-bottom: 24px;
}

.arth-fc-field__label-row {
    display: flex;
    gap: 14px;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 11px;
}

.arth-fc-field label {
    color: var(--arth-text);
    font-size: 14px;
    font-weight: 750;
}

.arth-fc-number-wrap {
    display: inline-flex;
    min-width: 154px;
    height: 43px;
    align-items: center;
    justify-content: flex-end;
    padding: 0 11px;
    border: 1px solid var(--arth-border);
    border-radius: 11px;
    background: #f8faf8;
    color: var(--arth-muted);
    font-size: 14px;
}

.arth-fc-number-wrap input {
    width: 90px;
    height: 39px;
    padding: 0 5px;
    border: 0 !important;
    background: transparent !important;
    box-shadow: none !important;
    color: var(--arth-primary);
    font: inherit;
    font-weight: 800;
    text-align: right;
    outline: none;
    appearance: textfield;
}

.arth-fc-number-wrap input::-webkit-inner-spin-button,
.arth-fc-number-wrap input::-webkit-outer-spin-button {
    margin: 0;
    appearance: none;
}

.arth-fc-field select {
    width: 100%;
    min-height: 49px;
    padding: 10px 42px 10px 14px;
    border: 1px solid var(--arth-border);
    border-radius: 12px;
    background-color: #f8faf8;
    color: var(--arth-primary);
    font: inherit;
    font-weight: 700;
    outline: none;
}

.arth-fc-range {
    --arth-range-fill: 50%;
    width: 100%;
    height: 6px;
    border: 0;
    border-radius: 999px;
    background: linear-gradient(to right, var(--arth-primary) 0, var(--arth-primary) var(--arth-range-fill), #dce4e1 var(--arth-range-fill), #dce4e1 100%);
    outline: none;
    appearance: none;
}

.arth-fc-range::-webkit-slider-thumb {
    width: 20px;
    height: 20px;
    border: 4px solid #fff;
    border-radius: 50%;
    background: var(--arth-primary);
    box-shadow: 0 2px 9px rgba(24, 48, 48, .28);
    cursor: pointer;
    appearance: none;
}

.arth-fc-range::-moz-range-thumb {
    width: 14px;
    height: 14px;
    border: 4px solid #fff;
    border-radius: 50%;
    background: var(--arth-primary);
    box-shadow: 0 2px 9px rgba(24, 48, 48, .28);
    cursor: pointer;
}

.arth-fc-error {
    min-height: 17px;
    margin-top: 6px;
    color: #b42318;
    font-size: 12px;
}

.arth-fc-field.has-error .arth-fc-number-wrap {
    border-color: #d92d20;
    box-shadow: 0 0 0 3px rgba(217, 45, 32, .08);
}

.arth-fc-form__actions,
.arth-fc-lead-box__actions {
    display: flex;
    gap: 11px;
    flex-wrap: wrap;
}

.arth-fc-button {
    display: inline-flex;
    min-height: 48px;
    padding: 11px 19px;
    align-items: center;
    justify-content: center;
    border: 1px solid transparent;
    border-radius: 12px;
    font: inherit;
    font-size: 14px;
    font-weight: 800;
    line-height: 1;
    text-decoration: none !important;
    cursor: pointer;
    transition: transform .2s ease, background .2s ease, border-color .2s ease;
}

.arth-fc-button:hover {
    transform: translateY(-1px);
}

.arth-fc-button--primary {
    background: var(--arth-primary);
    color: #fff !important;
}

.arth-fc-button--ghost {
    border-color: var(--arth-border);
    background: #f6f8f6;
    color: var(--arth-primary);
}

.arth-fc-button--outline {
    border-color: rgba(255,255,255,.5);
    background: transparent;
    color: #fff !important;
}

.arth-fc-results {
    background:
        radial-gradient(circle at 100% 0, rgba(201, 165, 107, .18), transparent 35%),
        #f5f8f5;
}

.arth-fc-results__heading {
    display: flex;
    gap: 15px;
    align-items: flex-start;
    justify-content: space-between;
}

.arth-fc-copy {
    padding: 7px 11px;
    border: 1px solid var(--arth-border);
    border-radius: 9px;
    background: #fff;
    color: var(--arth-primary);
    font: inherit;
    font-size: 12px;
    font-weight: 800;
    cursor: pointer;
}

.arth-fc-highlight {
    display: flex;
    justify-content: center;
    padding: 5px 0 24px;
}

.arth-fc-donut {
    --arth-fill: 55%;
    display: grid;
    width: 210px;
    height: 210px;
    place-items: center;
    border-radius: 50%;
    background: conic-gradient(var(--arth-accent) 0 var(--arth-fill), #dce5df var(--arth-fill) 100%);
    position: relative;
}

.arth-fc-donut::before {
    content: '';
    position: absolute;
    inset: 15px;
    border-radius: 50%;
    background: #fff;
    box-shadow: inset 0 0 0 1px rgba(24, 48, 48, .05);
}

.arth-fc-donut > div {
    position: relative;
    z-index: 1;
    width: 145px;
    text-align: center;
}

.arth-fc-donut strong {
    display: block;
    color: var(--arth-primary);
    font-size: clamp(22px, 3vw, 29px);
    line-height: 1.15;
    overflow-wrap: anywhere;
}

.arth-fc-donut span {
    display: block;
    margin-top: 7px;
    color: var(--arth-muted);
    font-size: 12px;
    line-height: 1.35;
}

.arth-fc-result-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 11px;
}

.arth-fc-result-card {
    min-height: 94px;
    padding: 15px;
    border: 1px solid rgba(24, 48, 48, .08);
    border-radius: 14px;
    background: rgba(255,255,255,.78);
}

.arth-fc-result-card span {
    display: block;
    margin-bottom: 7px;
    color: var(--arth-muted);
    font-size: 12px;
    line-height: 1.35;
}

.arth-fc-result-card strong {
    display: block;
    color: var(--arth-primary);
    font-size: 18px;
    line-height: 1.25;
    overflow-wrap: anywhere;
}

.arth-fc-result-note,
.arth-fc-specific-note,
.arth-fc-disclaimer {
    margin-top: 16px;
    padding: 14px 16px;
    border: 1px solid var(--arth-border);
    border-radius: 13px;
    background: #fff;
    color: var(--arth-muted);
    font-size: 13px;
    line-height: 1.65;
}

.arth-fc-result-note {
    border-left: 4px solid var(--arth-accent);
}

.arth-fc-lead-box {
    margin-top: 18px;
    padding: 21px;
    border-radius: 17px;
    background: var(--arth-primary);
    color: #fff;
}

.arth-fc-lead-box h3 {
    margin: 0 0 7px;
    color: #fff;
    font-size: 20px;
}

.arth-fc-lead-box p {
    margin: 0 0 16px;
    color: rgba(255,255,255,.76);
    font-size: 13px;
    line-height: 1.6;
}

.arth-fc-lead-box .arth-fc-button--primary {
    background: #fff;
    color: var(--arth-primary) !important;
}

.arth-fc-related {
    margin-top: 42px;
}

.arth-fc-related__heading {
    margin-bottom: 18px;
}

.arth-fc-related__grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 14px;
}

.arth-fc-related__card {
    display: grid;
    grid-template-columns: 46px 1fr auto;
    gap: 13px;
    min-height: 112px;
    padding: 18px;
    align-items: center;
    border: 1px solid var(--arth-border);
    border-radius: 16px;
    background: #fff;
    color: var(--arth-primary);
    text-decoration: none !important;
    transition: transform .2s ease, box-shadow .2s ease;
}

.arth-fc-related__card:hover {
    transform: translateY(-3px);
    box-shadow: 0 12px 30px rgba(24, 48, 48, .08);
}

.arth-fc-related__card > span {
    display: inline-flex;
    width: 46px;
    height: 46px;
    align-items: center;
    justify-content: center;
    border-radius: 12px;
    background: #e8efeb;
    font-size: 12px;
    font-weight: 900;
}

.arth-fc-related__card strong,
.arth-fc-related__card small {
    display: block;
}

.arth-fc-related__card strong {
    margin-bottom: 5px;
    font-size: 15px;
}

.arth-fc-related__card small {
    color: var(--arth-muted);
    font-size: 12px;
    line-height: 1.45;
}

.arth-fc-related__card b {
    font-size: 20px;
}

.screen-reader-text {
    position: absolute !important;
    width: 1px !important;
    height: 1px !important;
    padding: 0 !important;
    margin: -1px !important;
    overflow: hidden !important;
    clip: rect(0, 0, 0, 0) !important;
    white-space: nowrap !important;
    border: 0 !important;
}

/* Directory toolbar fixes: prevent the first filter from being clipped and
   remove theme spacing before the plugin-managed directory content. */
body.arth-fc-directory-page-active .site-content,
body.arth-fc-directory-page-active #content,
body.arth-fc-directory-page-active .site-main,
body.arth-fc-directory-page-active article.page,
body.arth-fc-directory-page-active .entry-content {
    margin-top: 0 !important;
    padding-top: 0 !important;
}

.arth-fc-directory-generated-page .arth-fc-toolbar,
.arth-fc-directory-generated-page .arth-fc-filters {
    overflow: visible;
}

@media (max-width: 1180px) {
    .arth-fc-toolbar {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 1024px) {
    .arth-fc-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .arth-fc-toolbar {
        grid-template-columns: 1fr;
    }

    .arth-fc-filters {
        justify-content: flex-start;
    }

    .arth-fc-calculator-shell {
        grid-template-columns: 1fr;
    }

    .arth-fc-related__grid {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 640px) {
    .arth-fc-directory,
    .arth-fc-single {
        padding-left: 2px;
        padding-right: 2px;
    }

    .arth-fc-directory__hero {
        padding: 30px 22px;
        border-radius: 21px;
    }

    .arth-fc-directory__hero p,
    .arth-fc-single__header p {
        font-size: 15px;
    }

    .arth-fc-grid {
        grid-template-columns: 1fr;
        gap: 14px;
    }

    .arth-fc-card {
        min-height: 245px;
        padding: 20px;
    }

    .arth-fc-single__header {
        gap: 14px;
    }

    .arth-fc-single__icon {
        flex-basis: 56px;
        width: 56px;
        height: 56px;
        border-radius: 15px;
        font-size: 14px;
    }

    .arth-fc-form,
    .arth-fc-results {
        padding: 21px 17px;
        border-radius: 18px;
    }

    .arth-fc-field__label-row {
        align-items: flex-start;
        flex-direction: column;
        gap: 8px;
    }

    .arth-fc-number-wrap {
        width: 100%;
        justify-content: flex-end;
    }

    .arth-fc-number-wrap input {
        width: 100%;
    }

    .arth-fc-result-grid {
        grid-template-columns: 1fr;
    }

    .arth-fc-form__actions,
    .arth-fc-lead-box__actions {
        flex-direction: column;
    }

    .arth-fc-button {
        width: 100%;
    }

    .arth-fc-donut {
        width: 190px;
        height: 190px;
    }
}

/* -------------------------------------------------------------------------
 * Auto-generated calculator page template (v1.3)
 * ---------------------------------------------------------------------- */
.arth-fc-generated-page {
    width: 100%;
    margin: 0;
    padding: 0;
    color: var(--arth-text);
    font-family: inherit;
}

.arth-fc-generated-page *,
.arth-fc-generated-page *::before,
.arth-fc-generated-page *::after {
    box-sizing: border-box;
}

.arth-fc-page-hero {
    --arth-fc-page-overlay: .64;
    --arth-fc-page-hero-height: 340px;
    position: relative;
    isolation: isolate;
    display: flex;
    width: 100vw;
    min-height: var(--arth-fc-page-hero-height);
    margin-left: calc(50% - 50vw);
    align-items: center;
    overflow: hidden;
    background-image:
        linear-gradient(rgba(15, 42, 44, var(--arth-fc-page-overlay)), rgba(15, 42, 44, var(--arth-fc-page-overlay))),
        var(--arth-fc-page-hero-image, linear-gradient(135deg, #24484a 0%, #183030 52%, #10272a 100%));
    background-position: center;
    background-size: cover;
}

.arth-fc-page-hero::before,
.arth-fc-page-hero::after {
    position: absolute;
    z-index: -1;
    content: "";
    pointer-events: none;
}

.arth-fc-page-hero::before {
    inset: 0;
    opacity: .24;
    background:
        linear-gradient(115deg, transparent 0 58%, rgba(255,255,255,.11) 58.15% 58.35%, transparent 58.5%),
        linear-gradient(22deg, transparent 0 71%, rgba(201,165,107,.4) 71.1% 71.35%, transparent 71.5%);
}

.arth-fc-page-hero::after {
    right: -8vw;
    bottom: -210px;
    width: 520px;
    height: 520px;
    border: 1px solid rgba(255,255,255,.14);
    border-radius: 50%;
    box-shadow: 0 0 0 65px rgba(255,255,255,.035), 0 0 0 130px rgba(255,255,255,.025);
}

.arth-fc-page-hero__inner {
    width: 100%;
    max-width: 1240px;
    margin: 0 auto;
    padding: 58px 24px 62px;
}

.arth-fc-page-hero__eyebrow {
    display: inline-block;
    margin-bottom: 12px;
    color: #e9d09b;
    font-size: 12px;
    font-weight: 800;
    letter-spacing: .16em;
    text-transform: uppercase;
}

.arth-fc-page-hero h1 {
    max-width: 850px;
    margin: 0;
    color: #fff;
    font-size: clamp(38px, 5vw, 64px);
    font-weight: 750;
    line-height: 1.08;
    letter-spacing: -.035em;
}

.arth-fc-page-hero__divider {
    display: flex;
    width: min(520px, 90%);
    align-items: center;
    gap: 10px;
    margin: 24px 0 18px;
    color: #fff;
}

.arth-fc-page-hero__divider span {
    display: block;
    height: 1px;
    flex: 1;
    background: rgba(255,255,255,.72);
}

.arth-fc-page-hero__divider b {
    font-size: 12px;
    line-height: 1;
}

.arth-fc-page-hero p {
    max-width: 760px;
    margin: 0;
    color: rgba(255,255,255,.9);
    font-size: 16px;
    line-height: 1.7;
}

.arth-fc-generated-page__content {
    width: 100%;
    max-width: 1280px;
    margin: 0 auto;
    padding: 58px 20px 82px;
}

.arth-fc-generated-page__content > .arth-fc-single {
    max-width: 1240px;
}

.arth-fc-generated-page__content .arth-fc-back {
    margin-bottom: 28px;
}

/* Hide duplicate titles produced by common WordPress themes only on pages
   created and managed by this plugin. */
body.arth-fc-hide-theme-title article.page > .entry-header,
body.arth-fc-hide-theme-title .site-main > article > .entry-header,
body.arth-fc-hide-theme-title .ast-article-single > .entry-header,
body.arth-fc-hide-theme-title .page-header:not(.site-header) {
    display: none !important;
}

body.arth-fc-generated-page-active .entry-content {
    margin-top: 0 !important;
}

body.arth-fc-generated-page-active .entry-content,
body.arth-fc-generated-page-active .site-main,
body.arth-fc-generated-page-active article.page {
    overflow: visible;
}

@media (max-width: 767px) {
    .arth-fc-page-hero {
        min-height: min(var(--arth-fc-page-hero-height), 390px);
    }

    .arth-fc-page-hero__inner {
        padding: 46px 20px 50px;
    }

    .arth-fc-page-hero h1 {
        font-size: clamp(34px, 10vw, 48px);
    }

    .arth-fc-page-hero p {
        font-size: 15px;
    }

    .arth-fc-generated-page__content {
        padding: 38px 16px 62px;
    }
}
