/* ============================================================
   StitchPro Content Pages – Frontend Styles
   ============================================================ */

:root {
    --sap-navy:   #1a3560;
    --sap-gold:   #f5c518;
    --sap-white:  #ffffff;
    --sap-text:   #2c2c2c;
    --sap-muted:  #555;
    --sap-border: #e0e0e0;
    --sap-bg:     #f7f8fa;
    --sap-radius: 8px;
    --sap-shadow: 0 2px 12px rgba(0,0,0,.08);
}

/* ── Page wrapper ──────────────────────────────────────────── */
.sap-page { font-family: inherit; color: var(--sap-text); }

.sap-container {
    max-width: 1100px;
    margin: 0 auto;
    padding: 0 20px;
}

/* ── Section base ──────────────────────────────────────────── */
.sap-section {
    padding: 64px 0;
}
.sap-section:nth-child(even) { background: var(--sap-bg); }

.sap-section__title {
    font-size: 2rem;
    font-weight: 700;
    color: var(--sap-navy);
    margin: 0 0 32px;
    padding-bottom: 12px;
    border-bottom: 3px solid var(--sap-gold);
    display: inline-block;
}
.sap-section__desc {
    color: var(--sap-muted);
    margin-bottom: 24px;
}

/* ── Hero ──────────────────────────────────────────────────── */
.sap-hero {
    padding: 80px 20px;
    text-align: center;
    position: relative;
}
.sap-hero__inner {
    max-width: 760px;
    margin: 0 auto;
}
.sap-hero__heading {
    font-size: clamp(2rem, 5vw, 3.2rem);
    font-weight: 800;
    margin: 0 0 16px;
    line-height: 1.15;
}
.sap-hero__subheading {
    font-size: 1.15rem;
    opacity: .88;
    margin: 0 0 28px;
    line-height: 1.6;
}

/* ── Buttons ───────────────────────────────────────────────── */
.sap-btn {
    display: inline-block;
    padding: 13px 30px;
    border-radius: 6px;
    font-weight: 700;
    font-size: 1rem;
    text-decoration: none;
    transition: transform .15s, box-shadow .15s;
}
.sap-btn:hover { transform: translateY(-2px); box-shadow: 0 4px 16px rgba(0,0,0,.2); }
.sap-btn--gold {
    background: var(--sap-gold);
    color: var(--sap-navy);
}

/* ── Prose ─────────────────────────────────────────────────── */
.sap-prose p  { margin: 0 0 1em; line-height: 1.75; }
.sap-prose ul,
.sap-prose ol { margin: 0 0 1em 1.4em; line-height: 1.75; }
.sap-prose li { margin-bottom: .4em; }
.sap-prose a  { color: var(--sap-navy); text-decoration: underline; }
.sap-prose h2,
.sap-prose h3 { color: var(--sap-navy); margin-top: 1.5em; }
.sap-prose strong { color: var(--sap-navy); }

/* ── Two-column ────────────────────────────────────────────── */
.sap-two-col {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 40px;
}
@media (max-width: 768px) { .sap-two-col { grid-template-columns: 1fr; } }

/* ── FAQ Accordion ─────────────────────────────────────────── */
.sap-accordion { display: flex; flex-direction: column; gap: 6px; }

.sap-accordion__item {
    border: 1px solid var(--sap-border);
    border-radius: var(--sap-radius);
    overflow: hidden;
    background: #fff;
}

.sap-accordion__trigger {
    width: 100%;
    text-align: left;
    background: none;
    border: none;
    padding: 18px 20px;
    font-size: 1rem;
    font-weight: 600;
    color: var(--sap-navy);
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    transition: background .15s;
}
.sap-accordion__trigger:hover { background: var(--sap-bg); }
.sap-accordion__trigger[aria-expanded="true"] { border-bottom: 1px solid var(--sap-border); }

.sap-accordion__icon {
    flex-shrink: 0;
    width: 20px;
    height: 20px;
    background: var(--sap-navy);
    border-radius: 50%;
    position: relative;
    transition: transform .25s;
}
.sap-accordion__icon::before,
.sap-accordion__icon::after {
    content: '';
    position: absolute;
    background: #fff;
    border-radius: 2px;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
}
.sap-accordion__icon::before { width: 10px; height: 2px; }
.sap-accordion__icon::after  { width: 2px; height: 10px; transition: transform .25s; }
.sap-accordion__trigger[aria-expanded="true"] .sap-accordion__icon::after {
    transform: translate(-50%, -50%) rotate(90deg);
}

.sap-accordion__body {
    max-height: 0;
    overflow: hidden;
    transition: max-height .3s ease;
}
.sap-accordion__body.is-open { max-height: 600px; }
.sap-accordion__body .sap-prose { padding: 16px 20px 20px; }

/* ── Features Grid ─────────────────────────────────────────── */
.sap-features {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
    gap: 24px;
}
.sap-feature {
    background: #fff;
    border: 1px solid var(--sap-border);
    border-radius: var(--sap-radius);
    padding: 28px 24px;
    text-align: center;
    box-shadow: var(--sap-shadow);
    transition: transform .2s;
}
.sap-feature:hover { transform: translateY(-4px); }
.sap-feature__icon {
    font-size: 2.4rem;
    margin-bottom: 14px;
    line-height: 1;
}
.sap-feature__title {
    font-size: 1.05rem;
    font-weight: 700;
    color: var(--sap-navy);
    margin: 0 0 8px;
}
.sap-feature__desc {
    font-size: .93rem;
    color: var(--sap-muted);
    margin: 0;
    line-height: 1.65;
}

/* ── Timeline ──────────────────────────────────────────────── */
.sap-timeline {
    position: relative;
    padding-left: 24px;
}
.sap-timeline::before {
    content: '';
    position: absolute;
    left: 20px;
    top: 0;
    bottom: 0;
    width: 2px;
    background: var(--sap-gold);
}

.sap-timeline__step {
    position: relative;
    display: flex;
    gap: 24px;
    padding-bottom: 36px;
}
.sap-timeline__step:last-child { padding-bottom: 0; }

.sap-timeline__marker {
    flex-shrink: 0;
    width: 40px;
    height: 40px;
    background: var(--sap-navy);
    color: var(--sap-gold);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 700;
    font-size: .95rem;
    position: relative;
    z-index: 1;
    margin-left: -4px;
    box-shadow: 0 0 0 4px #fff, 0 0 0 5px var(--sap-gold);
}

.sap-timeline__content { padding-top: 6px; }
.sap-timeline__content h3 {
    font-size: 1.05rem;
    font-weight: 700;
    color: var(--sap-navy);
    margin: 0 0 6px;
}
.sap-timeline__content p {
    color: var(--sap-muted);
    margin: 0;
    line-height: 1.65;
}

/* ── Color Palette ─────────────────────────────────────────── */
.sap-palette {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(130px, 1fr));
    gap: 16px;
}
.sap-swatch {
    border-radius: var(--sap-radius);
    padding: 12px;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 4px;
    cursor: pointer;
    box-shadow: var(--sap-shadow);
    min-height: 90px;
    justify-content: center;
    border: 1px solid rgba(0,0,0,.08);
    transition: transform .15s;
    text-align: center;
}
.sap-swatch:hover { transform: scale(1.04); }
.sap-swatch__name { font-size: .8rem; font-weight: 600; }
.sap-swatch__code { font-size: .72rem; opacity: .8; font-family: monospace; }

.sap-swatch-copied {
    position: fixed;
    bottom: 24px;
    right: 24px;
    background: var(--sap-navy);
    color: var(--sap-gold);
    padding: 10px 18px;
    border-radius: 6px;
    font-weight: 600;
    z-index: 9999;
    animation: sapFadeUp .3s ease;
}
@keyframes sapFadeUp {
    from { opacity: 0; transform: translateY(10px); }
    to   { opacity: 1; transform: translateY(0); }
}

/* ── Font List ─────────────────────────────────────────────── */
.sap-font-list { display: flex; flex-direction: column; gap: 12px; }

.sap-font-item {
    background: #fff;
    border: 1px solid var(--sap-border);
    border-radius: var(--sap-radius);
    display: grid;
    grid-template-columns: 1fr 1fr;
    align-items: center;
    overflow: hidden;
}
@media (max-width: 600px) { .sap-font-item { grid-template-columns: 1fr; } }

.sap-font-item__sample {
    padding: 24px;
    font-size: 1.6rem;
    background: var(--sap-bg);
    border-right: 1px solid var(--sap-border);
    text-align: center;
    color: var(--sap-navy);
}
.sap-font-item--uppercase  .sap-font-item__sample { text-transform: uppercase; font-weight: 900; letter-spacing: 2px; }
.sap-font-item--script     .sap-font-item__sample { font-style: italic; font-weight: 400; }
.sap-font-item--collegiate .sap-font-item__sample { font-weight: 900; text-transform: uppercase; letter-spacing: 1px; }
.sap-font-item--varsity    .sap-font-item__sample { font-weight: 900; text-transform: uppercase; }
.sap-font-item--serif      .sap-font-item__sample { font-family: Georgia, serif; }
.sap-font-item--gothic     .sap-font-item__sample { font-weight: 900; }

.sap-font-item__info {
    padding: 20px 24px;
    display: flex;
    flex-direction: column;
    gap: 4px;
}
.sap-font-item__info strong { color: var(--sap-navy); font-size: 1rem; }
.sap-font-item__info span   { color: var(--sap-muted); font-size: .9rem; }

/* ── Empty state ───────────────────────────────────────────── */
.sap-empty {
    padding: 40px;
    text-align: center;
    color: var(--sap-muted);
    background: var(--sap-bg);
    border-radius: var(--sap-radius);
}
