
.cd-app-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 24px; margin-bottom: 24px; }
@media (max-width: 900px) { .cd-app-grid { grid-template-columns: 1fr; } }
.cd-card { background: #ffffff; border: 1px solid #e2e8f0; border-radius: 14px; padding: 20px; box-shadow: 0 4px 16px rgba(0,0,0,0.04); }
.cd-display-board { background: linear-gradient(135deg, #0f172a 0%, #1e293b 100%); color: #ffffff; border-radius: 14px; padding: 24px; text-align: center; box-shadow: 0 10px 25px rgba(0,0,0,0.2); margin-bottom: 16px; position: relative; }
.cd-grid-units { display: grid; grid-template-columns: repeat(4, 1fr); gap: 10px; margin-top: 14px; }
.cd-unit-box { background: rgba(255, 255, 255, 0.08); border: 1px solid rgba(255, 255, 255, 0.15); border-radius: 10px; padding: 12px 6px; }
.cd-unit-num { font-size: 2.4rem; font-weight: 900; line-height: 1; letter-spacing: -1px; color: #10b981; }
.cd-unit-lbl { font-size: 11px; text-transform: uppercase; color: #94a3b8; font-weight: 700; margin-top: 4px; }
.cd-presets { display: flex; flex-wrap: wrap; gap: 6px; margin-bottom: 14px; }
.cd-preset-btn { font-size: 11px; padding: 5px 10px; border-radius: 6px; border: 1px solid #e2e8f0; background: #f8fafc; cursor: pointer; font-weight: 600; color: #334155; transition: all 0.15s; }
.cd-preset-btn:hover { border-color: #059669; color: #059669; background: #ecfdf5; }
.cd-btn { padding: 9px 14px; border-radius: 8px; font-size: 12px; font-weight: 700; cursor: pointer; border: none; display: inline-flex; align-items: center; gap: 6px; text-decoration: none; transition: all 0.15s ease; }
.cd-btn-primary { background: #059669; color: #fff; }
.cd-btn-primary:hover { background: #047857; }
.cd-btn-secondary { background: #f1f5f9; color: #334155; border: 1px solid #cbd5e1; }
.cd-btn-secondary:hover { background: #e2e8f0; }

/* Fullscreen Stage */
.cd-fullscreen-mode { position: fixed !important; top: 0 !important; left: 0 !important; width: 100vw !important; height: 100vh !important; z-index: 99999 !important; border-radius: 0 !important; display: flex !important; flex-direction: column !important; justify-content: center !important; align-items: center !important; }
.cd-fullscreen-mode .cd-unit-num { font-size: 5rem !important; }
.cd-fullscreen-mode .cd-grid-units { width: 85% !important; max-width: 900px !important; }

@media print {
  body * { visibility: hidden; }
  #cdPrintArea, #cdPrintArea * { visibility: visible; }
  #cdPrintArea { position: absolute; left: 0; top: 0; width: 100%; display: block !important; padding: 20px; font-family: sans-serif; }
}

/* ── Modal, A4 & toast (standar v2.63) ── */
.modal-overlay {
    position: fixed;
    inset: 0;
    background: rgba(10, 22, 18, 0.68);
    backdrop-filter: blur(4px);
    z-index: 1000;
    display: none;
    align-items: center;
    justify-content: center;
    padding: 1rem;
}
.modal-overlay.open { display: flex; }
.modal-dialog {
    background: var(--psg-card);
    border: 1px solid var(--psg-border-strong);
    border-radius: 16px;
    max-width: 760px;
    width: 100%;
    max-height: 90vh;
    display: flex;
    flex-direction: column;
    box-shadow: 0 16px 40px rgba(0,0,0,0.16);
    overflow: hidden;
}
.modal-head {
    padding: 1rem 1.25rem;
    background: var(--psg-surface);
    border-bottom: 1px solid var(--psg-border);
    display: flex;
    align-items: center;
    justify-content: space-between;
}
.modal-body {
    padding: 1.25rem;
    overflow-y: auto;
}
.modal-foot {
    padding: 0.85rem 1.25rem;
    background: var(--psg-surface);
    border-top: 1px solid var(--psg-border);
    display: flex;
    align-items: center;
    justify-content: flex-end;
    gap: 0.6rem;
}

.a4-paper {
    background: #ffffff;
    color: #0f172a;
    border: 1px solid #cbd5e1;
    border-radius: 8px;
    padding: 2rem;
    font-family: inherit;
    box-shadow: 0 4px 12px rgba(0,0,0,0.06);
}
.a4-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    border-bottom: 2.5px solid #1a3c34;
    padding-bottom: 0.85rem;
    margin-bottom: 1.25rem;
}
.a4-table {
    width: 100%;
    border-collapse: collapse;
    font-size: 0.82rem;
    margin-bottom: 1.25rem;
}
.a4-table th, .a4-table td {
    border: 1px solid #cbd5e1;
    padding: 0.55rem 0.75rem;
    text-align: left;
}
.a4-table th {
    background: #f1f5f9;
    font-weight: 700;
    color: #0f172a;
}

.toast-container {
    position: fixed;
    bottom: 1.25rem;
    right: 1.25rem;
    z-index: 2000;
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}
.toast-msg {
    background: var(--psg-primary);
    color: #ffffff;
    padding: 0.7rem 1rem;
    border-radius: 8px;
    font-size: 0.82rem;
    font-weight: 600;
    box-shadow: 0 8px 24px rgba(0,0,0,0.15);
    display: flex;
    align-items: center;
    gap: 0.5rem;
    animation: slideUp 0.2s ease;
}
@keyframes slideUp {
    from { opacity: 0; transform: translateY(10px); }
    to { opacity: 1; transform: translateY(0); }
}

