/* =============================================================
   DUE DATE CALCULATOR - CalcLeaf light theme
   All classes prefixed "ddc-" to avoid collisions with other tools.
   ============================================================= */

.ddc-tool {
    max-width: 800px;
    margin: 0 auto;
    font-family: inherit;
    color: #1e2a4a;
}

.ddc-card {
    background: #ffffff;
    border: 1px solid #d1d5db;
    border-radius: 8px;
    overflow: hidden;
    margin-top: 20px;
}

.ddc-hint {
    background: #1e2a4a;
    color: #ffffff;
    font-size: 13px;
    padding: 10px 16px;
    display: flex;
    align-items: center;
    gap: 8px;
}

.ddc-hint-icon {
    font-size: 11px;
}

.ddc-form {
    padding: 18px 16px;
}

.ddc-row {
    display: flex;
    align-items: center;
    gap: 12px;
    flex-wrap: wrap;
    margin-bottom: 14px;
}

.ddc-row label {
    width: 200px;
    flex-shrink: 0;
    font-size: 14px;
    font-weight: 600;
    color: #374151;
}

.ddc-inline-label {
    width: auto !important;
    margin-left: 6px;
}

.ddc-input,
.ddc-select {
    padding: 8px 10px;
    border: 1px solid #d1d5db;
    border-radius: 6px;
    font-size: 14px;
    color: #1e2a4a;
    background: #ffffff;
}

.ddc-input:focus,
.ddc-select:focus {
    outline: none;
    border-color: #10b981;
    box-shadow: 0 0 0 3px rgba(16, 185, 129, 0.15);
}

.ddc-input-small {
    width: 70px;
}

.ddc-select-small {
    width: auto;
}

.ddc-unit {
    font-size: 13px;
    color: #6b7280;
}

/* ---------- Buttons ---------- */
.ddc-actions {
    display: flex;
    gap: 10px;
    margin-top: 8px;
}

.ddc-btn {
    padding: 10px 28px;
    border-radius: 6px;
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    border: 1px solid transparent;
    transition: opacity 0.15s;
}

.ddc-btn:hover {
    opacity: 0.9;
}

.ddc-btn-primary {
    background: #10b981;
    color: #ffffff;
}

.ddc-btn-secondary {
    background: #f3f4f6;
    color: #6b7280;
    border-color: #d1d5db;
}

/* ---------- Results ---------- */
.ddc-result-card {
    background: #ffffff;
    border: 1px solid #d1d5db;
    border-radius: 8px;
    overflow: hidden;
    margin-bottom: 20px;
}

.ddc-result-header {
    background: #10b981;
    color: #ffffff;
    font-weight: 700;
    font-size: 16px;
    padding: 12px 16px;
}

.ddc-result-body {
    padding: 16px;
}

.ddc-due-headline {
    font-size: 18px;
    font-weight: 700;
    color: #1e2a4a;
    margin-bottom: 10px;
}

.ddc-result-body p {
    font-size: 14px;
    color: #374151;
    margin-bottom: 8px;
}

.ddc-progress-wrap {
    position: relative;
    background: #e5e7eb;
    border-radius: 999px;
    height: 22px;
    margin-top: 14px;
    overflow: hidden;
}

.ddc-progress-bar {
    height: 100%;
    background: linear-gradient(90deg, #ec4899, #f472b6);
    border-radius: 999px;
    transition: width 0.3s;
}

.ddc-progress-text {
    position: absolute;
    top: 0;
    left: 50%;
    transform: translateX(-50%);
    line-height: 22px;
    font-size: 12px;
    font-weight: 700;
    color: #ffffff;
    text-shadow: 0 1px 1px rgba(0,0,0,0.25);
}

/* ---------- Schedule table ---------- */
.ddc-schedule-card {
    background: #ffffff;
    border: 1px solid #d1d5db;
    border-radius: 8px;
    overflow: hidden;
    padding-bottom: 12px;
}

.ddc-table {
    width: 100%;
    border-collapse: collapse;
    font-size: 13px;
}

.ddc-table thead th {
    background: #1e2a4a;
    color: #ffffff;
    text-align: left;
    padding: 10px 12px;
    font-weight: 600;
}

.ddc-table tbody td {
    padding: 8px 12px;
    border-top: 1px solid #f0f0f0;
    color: #374151;
    vertical-align: top;
}

.ddc-trimester-cell {
    background: #f3f4f6;
    text-align: center;
    font-weight: 600;
    color: #6b7280;
    vertical-align: middle !important;
}

.ddc-milestone-cell {
    color: #10b981;
    font-weight: 600;
}

.ddc-current-week {
    background: #ecfdf5;
}

.ddc-current-week td {
    font-weight: 700;
}

.ddc-note {
    font-size: 12px;
    color: #9ca3af;
    padding: 10px 16px 0 16px;
    line-height: 1.5;
}

/* ---------- Responsive ---------- */
@media (max-width: 640px) {
    .ddc-row {
        flex-direction: column;
        align-items: flex-start;
        gap: 6px;
    }

    .ddc-row label {
        width: auto;
    }

    .ddc-actions {
        flex-direction: column;
    }

    .ddc-btn {
        width: 100%;
    }

    .ddc-table {
        font-size: 12px;
    }
}
