/* ==========================================================================
   ORDER CONFIGURE — "Choose Billing Cycle" picker (StoreController::configure(), cycleRows()).
   One row per cycle: radio, label, per-month price + saving, Pay Now. Client tokens (--p-*) from portal.css.
   ========================================================================== */

.cyc-card { padding: 22px 22px 24px !important; border-radius: 16px !important; }
.cyc-title {
    display: flex; align-items: center; gap: 10px;
    margin: 0 0 18px; padding-bottom: 16px;
    border-bottom: 1px solid var(--p-border);
    font-size: 16.5px; font-weight: 700; color: var(--p-text);
}
.cyc-title svg { color: var(--p-primary); flex: 0 0 auto; }

.cyc-list { display: grid; gap: 14px; }
.cyc-row {
    --cyc-accent: #f97316;
    position: relative;
    display: grid; grid-template-columns: auto minmax(84px, 120px) minmax(0, 1fr) auto; align-items: center; gap: 12px;
    margin: 0; padding: 15px 18px;
    border: 1.5px solid var(--p-border); border-radius: 12px;
    background: var(--p-card);
    cursor: pointer;
    transition: border-color .15s, background-color .15s, box-shadow .15s;
}
.cyc-row:hover { border-color: color-mix(in srgb, var(--cyc-accent) 45%, var(--p-border)); }
.cyc-row.is-best { border-color: color-mix(in srgb, var(--cyc-accent) 55%, var(--p-border)); }
.cyc-row.is-selected, .cyc-row:has(.cyc-radio:checked) {
    border-color: var(--cyc-accent);
    background: color-mix(in srgb, var(--cyc-accent) 6%, var(--p-card));
    box-shadow: 0 0 0 3px color-mix(in srgb, var(--cyc-accent) 14%, transparent);
}
.cyc-row:has(.cyc-radio:focus-visible) { outline: 2px solid var(--cyc-accent); outline-offset: 3px; }

/* Real radio input, restyled (stays focusable and keyboard-operable) */
.cyc-radio {
    appearance: none; -webkit-appearance: none;
    width: 20px; height: 20px; margin: 0;
    border: 1.5px solid color-mix(in srgb, var(--p-text) 22%, transparent); border-radius: 50%;
    background: var(--p-card);
    cursor: pointer;
    display: grid; place-items: center;
}
.cyc-radio::after { content: ""; width: 10px; height: 10px; border-radius: 50%; transform: scale(0); background: var(--cyc-accent); transition: transform .12s; }
.cyc-radio:checked { border-color: var(--cyc-accent); }
.cyc-radio:checked::after { transform: scale(1); }
.cyc-radio:focus-visible { outline: none; }

.cyc-label { font-size: 15.5px; font-weight: 700; color: var(--p-text); white-space: nowrap; }
.cyc-price { display: flex; align-items: center; flex-wrap: wrap; gap: 4px 8px; min-width: 0; }
.cyc-price strong { font-size: 15.5px; font-weight: 700; color: var(--p-text); white-space: nowrap; }
.cyc-price strong small { font-size: inherit; font-weight: inherit; }
.cyc-save {
    padding: 3px 8px; border-radius: 6px;
    background: #f59e0b; color: #fff;
    font-style: normal; font-size: 12px; font-weight: 700; white-space: nowrap;
}
.cyc-regular { font-size: 12.5px; color: var(--p-muted); white-space: nowrap; }
.cyc-setup { display: none; font-size: 13px; font-weight: 500; color: var(--p-text-2); white-space: nowrap; }
.cyc-setup.is-free { color: var(--p-success); }
.cyc-row.is-selected .cyc-setup, .cyc-row:has(.cyc-radio:checked) .cyc-setup { display: inline; }
.cyc-pay { font-size: 14.5px; font-weight: 700; color: var(--p-primary); white-space: nowrap; text-align: right; }
.cyc-pay b { font-weight: inherit; }

.cyc-tag {
    position: absolute; left: 50%; top: 0; transform: translate(-50%, -55%);
    padding: 3px 11px; border-radius: 999px;
    font-size: 10.5px; font-weight: 800; letter-spacing: .05em; text-transform: uppercase; white-space: nowrap;
    color: #fff; box-shadow: 0 0 0 3px var(--p-card);
}
.cyc-tag-best { background: var(--p-primary); }
.cyc-tag-max { background: #10b981; }

:root[data-theme="dark"] .cyc-save { background: #d97706; }

/* Phones: price line drops under the label, Pay Now under that */
@media (max-width: 720px) {
    .cyc-card { padding: 18px 14px 20px !important; }
    .cyc-row { grid-template-columns: auto minmax(0, 1fr); gap: 6px 12px; padding: 16px 14px 14px; }
    .cyc-radio { grid-row: 1 / span 3; align-self: start; margin-top: 2px; }
    .cyc-label, .cyc-price, .cyc-pay { grid-column: 2; }
    .cyc-pay { text-align: left; }
    .cyc-tag { left: auto; right: 14px; transform: translateY(-55%); }
}
