/* Deal or No Deal - page-specific styles only
   Relies on site-wide variables and layout from styles.css :root
   No resets, no header/footer duplication
*/

/* Page spacing override (optional per-tool) */
.site-main {
    --page-top: 1.25rem;
}

/* Layout */
.tool-grid {
    margin-top: 1rem;
    display: grid;
    grid-template-columns: 1.2fr 0.8fr;
    gap: 1rem;
}

@media (max-width: 900px) {
    .tool-grid {
        grid-template-columns: 1fr;
    }
}

/* Generic panel/card container */
.panel {
    background: var(--card);
    border: 1px solid rgba(255, 255, 255, .08);
    border-radius: 14px;
    padding: 1rem;
    box-shadow: 0 10px 30px rgba(0, 0, 0, .25);
}

.panel-title {
    margin: 0 0 .35rem;
    font-size: 1.05rem;
}

.panel-subtitle {
    margin: 0 0 1rem;
    color: var(--muted);
    font-size: .95rem;
}

.muted {
    color: var(--muted);
}

/* Optional hero tweak (keeps global styles, just tightens spacing a bit) */
.hero {
    padding: 1.25rem 1.4rem;
}

.hero h1 {
    margin: .1rem 0 .4rem;
    font-size: 1.7rem;
}

.hero p {
    margin: 0;
    color: var(--muted);
}

/* Two-option comparison layout inside the form */
.compare-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1rem;
}

@media (max-width: 900px) {
    .compare-grid {
        grid-template-columns: 1fr;
    }
}

.compare-card {
    border: 1px solid rgba(255, 255, 255, .10);
    border-radius: 12px;
    padding: .9rem;
    background: rgba(0, 0, 0, .12);
}

.compare-head h3 {
    margin: 0 0 .15rem;
    font-size: 1.05rem;
}

.compare-head p {
    margin: 0 0 .75rem;
    color: var(--muted);
    font-size: .9rem;
}

/* Form rows */
.row {
    display: flex;
    gap: .75rem;
    align-items: center;
    margin: .6rem 0;
    flex-wrap: wrap;
}

.row label {
    min-width: 110px;
    color: #d7e2ee;
    font-weight: 600;
}

.row .grow {
    flex: 1 1 240px;
}

/* Inputs & selects */
.input,
.select {
    width: 100%;
    padding: .65rem .7rem;
    border: 1px solid rgba(255, 255, 255, .12);
    border-radius: 10px;
    background: #0c101a;
    color: #e8ebf1;
    outline: none;
}

.input:focus,
.select:focus {
    border-color: var(--ring);
    box-shadow: 0 0 0 4px rgba(14, 118, 188, .15);
}

/* Buttons */
.btn {
    appearance: none;
    border: 1px solid rgba(255, 255, 255, .16);
    background: #0f1320;
    color: #e8ebf1;
    border-radius: 10px;
    padding: .55rem .75rem;
    font-weight: 700;
    cursor: pointer;
}

.btn:hover {
    filter: brightness(1.06);
}

.btn.primary {
    background: var(--blue);
    color: #fff;
}

.btn.ghost {
    background: transparent;
}

.btn[disabled] {
    opacity: .5;
    cursor: not-allowed;
}

.actions {
    display: flex;
    gap: .6rem;
    margin-top: 1rem;
    flex-wrap: wrap;
}

.hint {
    margin: .9rem 0 0;
    color: var(--muted);
    font-size: .9rem;
}

/* Results panel */
.results .result-box {
    border: 1px dashed rgba(255, 255, 255, .18);
    border-radius: 12px;
    padding: .9rem;
    background: rgba(0, 0, 0, .10);
}

.result-details {
    margin-top: 1rem;
    display: grid;
    gap: .6rem;
}

.detail-row {
    display: flex;
    justify-content: space-between;
    gap: 1rem;
    padding: .65rem .75rem;
    border: 1px solid rgba(255, 255, 255, .10);
    border-radius: 12px;
    background: rgba(0, 0, 0, .10);
}

.detail-row.winner {
    border-color: rgba(14, 118, 188, .35);
}

/* Winner highlighting */
.compare-card.is-winner {
    border-color: rgba(46, 204, 113, .65);
    /* green */
    box-shadow:
        0 0 0 2px rgba(46, 204, 113, .25),
        0 12px 34px rgba(46, 204, 113, .12);
}

.compare-card.is-loser {
    border-color: rgba(255, 255, 255, .10);
    opacity: .92;
}

/* Optional: a tiny nudge so the winner feels "active" */
.compare-card.is-winner .compare-head h3 {
    color: rgba(180, 255, 215, .95);
}