/* ==========================================================================
   Digital Drape Wheel — [tm_drape_wheel]
   Light theme; matches free-tool cards on tonematch.pro pages.
   ========================================================================== */

.tm-dwheel-card {
    --tmdw-bg: #ffffff;
    --tmdw-bg-soft: #f4f1ec;
    --tmdw-line: #e4dfd7;
    --tmdw-text: #1c1917;
    --tmdw-muted: #8c5dab;
    --tmdw-accent: #5c287e;
    --tmdw-accent-soft: rgba(109, 61, 242, 0.1);
    margin: 0 auto;
    padding: 28px;
    border-radius: 18px;
    background: var(--tmdw-bg);
    border: 1px solid var(--tmdw-line);
    color: var(--tmdw-text);
    font-family: 'Plus Jakarta Sans', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    box-shadow: 0 1px 2px rgba(28, 25, 23, 0.04);
}

header.tm-dwheel-seo-header,
.tm-dwheel-card,
nav.tm-dwheel-season-index,
section.tm-dwheel-faq,
aside.tm-dwheel-related {
    max-width: 720px !important;    
}

.tm-dwheel-title {
    margin: 0 0 6px;
    font-family: Fraunces, Georgia, serif;
    font-size: 1.5rem;
    font-weight: 500;
    color: var(--tmdw-text);
}

.tm-dwheel-intro {
    margin: 0 0 20px;
    font-size: 0.92rem;
    line-height: 1.55;
}

/* ---- Upload zone -------------------------------------------------------- */
.tm-dwheel-drop {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 6px;
    padding: 30px 20px;
    border: 1.5px dashed #cfc8bd;
    border-radius: 14px;
    background: var(--tmdw-bg-soft);
    cursor: pointer;
    text-align: center;
    transition: border-color 0.15s ease, background 0.15s ease;
}

.tm-dwheel-drop:hover,
.tm-dwheel-drop.is-drag {
    border-color: var(--tmdw-accent);
    background: var(--tmdw-accent-soft);
}

.tm-dwheel-drop-icon {
    color: #5c287e;
}
.tm-dwheel-drop-label {
    font-weight: 600;
    font-size: 0.98rem;
}

.tm-dwheel-drop-hint {
    color: var(--tmdw-muted);
    font-size: 0.8rem;
}

.tm-dwheel-hint {
    margin: 14px 0 0;
    color: var(--tmdw-muted);
    font-size: 0.82rem;
    line-height: 1.5;
}

/* ---- Mode tabs ----------------------------------------------------------- */
.tm-dwheel-tabs {
    display: flex;
    gap: 8px;
    margin: 22px 0 14px;
    flex-wrap: wrap;
}

.tm-dwheel-tab {
    padding: 8px 14px;
    border-radius: 999px;
    background: var(--tmdw-bg-soft);
    color: var(--tmdw-muted);
    font: inherit;
    font-size: 0.85rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.15s ease;
}

.tm-dwheel-tab.is-active {
    background: #5c287e;
    color: #fff;
}

/* ---- Season chips --------------------------------------------------------- */
.tm-dwheel-chips {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(150px, 1fr));
    gap: 8px;
    margin-bottom: 16px;
}

.tm-dwheel-chip {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 8px 10px;
    border-radius: 10px;
    border: 1px solid var(--tmdw-line);
    background: #fff;
    color: var(--tmdw-text);
    font: inherit;
    font-size: 0.8rem;
    cursor: pointer;
    text-align: left;
    transition: border-color 0.15s ease, box-shadow 0.15s ease;
}

.tm-dwheel-chip.is-on {
    border-color: var(--tmdw-accent);
    box-shadow: 0 0 0 1px var(--tmdw-accent);
    background: var(--tmdw-accent-soft);
}

.tm-dwheel-chip.is-disabled {
    opacity: 0.75;
    cursor: default;
}

.tm-dwheel-chip-swatches {
    display: inline-flex;
    flex-shrink: 0;
    border-radius: 5px;
    overflow: hidden;
}

.tm-dwheel-chip-swatches i {
    width: 9px;
    height: 20px;
    display: block;
}

.tm-dwheel-chip-name {
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

/* ---- Caption -------------------------------------------------------------- */
.tm-dwheel-caption-row {
    display: flex;
    flex-direction: column;
    gap: 6px;
    margin-bottom: 16px;
}

.tm-dwheel-caption-label {
    font-size: 0.8rem;
    color: var(--tmdw-muted);
    font-weight: 600;
}

.tm-dwheel-caption {
    padding: 10px 12px;
    border-radius: 10px;
    border: 1px solid var(--tmdw-line);
    background: #fff;
    color: var(--tmdw-text);
    font: inherit;
    font-size: 0.9rem;
}

.tm-dwheel-caption:focus {
    outline: none;
    border-color: var(--tmdw-accent);
}

/* ---- Preview + actions ------------------------------------------------------ */
.tm-dwheel-stage {
    border-radius: 14px;
    overflow: hidden;
    background: var(--tmdw-bg-soft);
    border: 1px solid var(--tmdw-line);
    line-height: 0;
}

.tm-dwheel-preview {
    width: 100%;
    height: auto;
    display: block;
}

.tm-dwheel-actions {
    margin-top: 14px;
    display: flex;
    justify-content: flex-end;
}

.tm-dwheel-download {
    padding: 11px 22px;
    border-radius: 10px;
    border: none;
    background: var(--tmdw-accent);
    color: #fff;
    font: inherit;
    font-size: 0.92rem;
    font-weight: 700;
    cursor: pointer;
    transition: filter 0.15s ease;
}

.tm-dwheel-download:hover { filter: brightness(1.08); }
.tm-dwheel-download:disabled { opacity: 0.6; cursor: wait; }

/* ---- Status ------------------------------------------------------------------ */
.tm-dwheel-status {
    margin: 12px 0 0;
    min-height: 1.2em;
    font-size: 0.82rem;
    color: var(--tmdw-muted);
}

.tm-dwheel-status.is-error { color: #b42318; }

.tm-dwheel-drape-row {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-bottom: 14px;
    font-size: 0.85rem;
    color: var(--tmdw-muted);
    cursor: pointer;
    user-select: none;
}

.tm-dwheel-drape-row input {
    accent-color: var(--tmdw-accent);
}

@media (max-width: 480px) {
    .tm-dwheel-card { padding: 18px; }
    .tm-dwheel-chips { grid-template-columns: repeat(2, 1fr); }
}

/* ---- White-balance pre-flight row ------------------------------------------ */
.tm-wb-row {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 11px 14px;
    margin-bottom: 14px;
    border-radius: 12px;
    border: 1px solid #fbbf24;
    background: rgba(251, 191, 36, 0.08);
    font-size: 0.85rem;
    line-height: 1.45;
}

.tm-wb-icon {
    flex-shrink: 0;
    color: #fbbf24;
}

.tm-wb-fix {
    margin-left: auto;
    flex-shrink: 0;
    padding: 8px 14px;
    border-radius: 9px;
    border: none;
    background: #5c287e;
    color: #fff;
    font: inherit;
    font-size: 0.82rem;
    font-weight: 700;
    cursor: pointer;
}

.tm-wb-fix:hover { filter: brightness(1.1); }

@media (max-width: 480px) {
    .tm-wb-row { flex-wrap: wrap; }
    .tm-wb-fix { margin-left: 0; }
}

/* ---- SEO shell (outside the interactive card) --------------------------- */
.tm-dwheel-seo {
    max-width: 760px;
    margin: 0 auto 40px;
    color: #1c1917;
    font-family: 'Plus Jakarta Sans', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
}

.tm-dwheel-seo-header {
    margin: auto;
    text-align: left;
}

.tm-dwheel-seo-eyebrow {
    margin: 0 0 8px;
    font-size: 0.72rem;
    font-weight: 700;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    color: #6b6560;
}

.tm-dwheel-seo-title {
    margin: 0 0 12px;
    font-family: Fraunces, Georgia, serif;
    font-size: clamp(1.65rem, 4vw, 2.15rem);
    font-weight: 500;
    line-height: 1.2;
    color: #1c1917;
}

.tm-dwheel-seo-lede {
    margin: 0;
    font-size: 1.05rem;
    line-height: 1.6;
    color: #6b6560;
}

.tm-dwheel-seo-h2 {
    margin: 0 0 10px;
    font-family: Fraunces, Georgia, serif;
    font-size: 1.25rem;
    font-weight: 500;
    color: #1c1917;
}

.tm-dwheel-seo-copy {
    margin: 0 0 12px;
    font-size: 0.95rem;
    line-height: 1.55;
    color: #6b6560;
}

.tm-dwheel-season-index,
.tm-dwheel-faq,
.tm-dwheel-related {
    margin: 1rem auto;
    padding: 24px 0 0;
    border-top: 1px solid #e4dfd7;
}

.tm-dwheel-season-list {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    list-style: none;
    margin: 0;
    padding: 0;
}

.tm-dwheel-season-list li {
    padding: 6px 12px;
    border-radius: 999px;
    border: 1px solid #e4dfd7;
    background: #f4f1ec;
    font-size: 0.82rem;
    font-weight: 600;
    color: #1c1917;
}

.tm-dwheel-faq-item {
    margin: 0 0 8px;
    border: 1px solid #e4dfd7;
    border-radius: 12px;
    background: #fff;
    padding: 0 14px;
}

.tm-dwheel-faq-item summary {
    cursor: pointer;
    list-style: none;
    padding: 14px 0;
    font-weight: 650;
    font-size: 0.95rem;
    color: #1c1917;
}

.tm-dwheel-faq-item summary::-webkit-details-marker { display: none; }

.tm-dwheel-faq-item summary::after {
    content: '+';
    float: right;
    color: #6b6560;
    font-weight: 500;
}

.tm-dwheel-faq-item[open] summary::after { content: '−'; }

.tm-dwheel-faq-item p {
    margin: 0 0 14px;
    font-size: 0.92rem;
    line-height: 1.6;
    color: #6b6560;
}

.tm-dwheel-related-list {
    margin: 0;
    padding-left: 1.15rem;
    font-size: 0.95rem;
    line-height: 1.6;
    color: #6b6560;
}

.tm-dwheel-related-list li { margin: 0 0 10px; }

.tm-dwheel-related-list a {
    color: #5c287e;
    font-weight: 650;
    text-underline-offset: 3px;
}

.tm-dwheel-related-list a:hover { color: #5c287e; }

@media (max-width: 480px) {
    .tm-dwheel-seo { margin-bottom: 28px; }
    .tm-dwheel-seo-title { font-size: 1.55rem; }
}
