/* =============================================
   DATE CALCULATOR — date.css
   Tool-specific styles only.
   Common styles are in tool.css
   ============================================= */

.date-calc { width: 100%; display: flex; flex-direction: column; gap: 24px; }

/* Section card */
.date-section {
    background: var(--white);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: 20px 24px;
    box-shadow: var(--shadow);
}
.date-section-title {
    font-size: 16px;
    font-weight: 700;
    color: var(--navy);
    margin-bottom: 8px;
    padding-bottom: 10px;
    border-bottom: 2px solid var(--teal);
    display: inline-block;
}
.date-desc {
    font-size: 13px;
    color: var(--text2);
    margin-bottom: 16px;
    line-height: 1.6;
}

/* Field row */
.date-field-row {
    display: flex;
    align-items: center;
    gap: 16px;
    margin-bottom: 12px;
    flex-wrap: wrap;
}
.date-field-label {
    font-size: 14px;
    font-weight: 600;
    color: var(--navy);
    min-width: 100px;
    text-align: right;
}
.date-inputs {
    display: flex;
    align-items: center;
    gap: 8px;
}

/* Reuse age select styles */
.age-select {
    padding: 8px 10px;
    border: 1px solid var(--border);
    border-radius: 8px;
    font-size: 14px;
    font-family: var(--font-main);
    color: var(--text);
    background: var(--white);
    outline: none;
    cursor: pointer;
    transition: border-color 0.2s;
}
.age-select:focus { border-color: var(--teal); box-shadow: 0 0 0 3px rgba(0,201,167,0.1); }
.age-select-day { width: 68px; }
.age-year-input {
    width: 88px;
    padding: 8px 10px;
    border: 1px solid var(--border);
    border-radius: 8px;
    font-size: 14px;
    font-family: var(--font-mono);
    color: var(--text);
    background: var(--white);
    outline: none;
    text-align: center;
    transition: border-color 0.2s;
    box-sizing: border-box;
}
.age-year-input:focus { border-color: var(--teal); }

/* Checkbox row */
.date-check-row {
    margin: 10px 0 14px;
    padding-left: 116px;
}
.date-checkbox-label {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 13px;
    color: var(--text2);
    cursor: pointer;
}
.date-checkbox-label input[type="checkbox"] {
    width: 16px;
    height: 16px;
    accent-color: var(--teal);
    cursor: pointer;
}

/* Add/Subtract grid */
.date-as-grid {
    display: flex;
    gap: 12px;
    align-items: flex-start;
    margin-bottom: 12px;
    padding-left: 116px;
}
.date-op-select {
    font-size: 20px;
    font-weight: 700;
    width: 60px;
    text-align: center;
    padding: 8px 6px;
    margin-top: 4px;
}
.date-as-fields { display: flex; flex-direction: column; gap: 8px; }
.date-as-row { display: flex; align-items: center; gap: 10px; }
.date-as-input {
    width: 100px;
    padding: 8px 12px;
    border: 1px solid var(--border);
    border-radius: 8px;
    font-size: 15px;
    font-family: var(--font-mono);
    color: var(--text);
    background: var(--white);
    outline: none;
    text-align: center;
    transition: border-color 0.2s;
    box-sizing: border-box;
}
.date-as-input:focus { border-color: var(--teal); box-shadow: 0 0 0 3px rgba(0,201,167,0.1); }
.date-as-unit {
    font-size: 14px;
    font-weight: 600;
    color: var(--navy);
    min-width: 60px;
}

/* Result box */
.date-result-box {
    margin-top: 16px;
    border: 1px solid var(--border);
    border-radius: var(--radius);
    overflow: hidden;
}
.date-result-header {
    background: linear-gradient(135deg, var(--navy) 0%, var(--navy2) 100%);
    color: #fff;
    font-size: 15px;
    font-weight: 700;
    padding: 10px 18px;
}

/* Answer cards */
.date-ans-cards {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 12px;
    padding: 16px;
    background: var(--light);
    border-bottom: 1px solid var(--border);
}
.date-ans-card {
    background: var(--white);
    border: 1px solid var(--border);
    border-radius: 8px;
    padding: 14px 16px;
}
.date-ans-card.highlight { border-color: var(--teal); background: #f0fdf9; }
.date-ans-label {
    font-size: 11px;
    font-weight: 700;
    color: var(--muted);
    text-transform: uppercase;
    letter-spacing: 0.04em;
    margin-bottom: 6px;
}
.date-ans-value {
    font-size: 28px;
    font-weight: 700;
    color: var(--teal);
    font-family: var(--font-mono);
    line-height: 1.2;
}
.date-ans-sub {
    font-size: 13px;
    color: var(--text2);
    margin-top: 4px;
}

/* Breakdown table */
.date-breakdown { padding: 14px 16px 16px; }
.date-table { width: 100%; }
.date-table td:last-child {
    text-align: right;
    font-family: var(--font-mono);
    color: var(--navy);
}

@media (max-width: 600px) {
    .date-field-label { min-width: 80px; text-align: left; }
    .date-check-row  { padding-left: 0; }
    .date-as-grid    { padding-left: 0; flex-direction: column; }
    .date-ans-cards  { grid-template-columns: 1fr; }
}
