/* ====== Shared Button Styles ====== */
.btn-sm { background: #27272a; color: #fafafa; border: 1px solid #3f3f46; padding: 6px 14px; border-radius: 6px; font-size: 12px; cursor: pointer; transition: all 0.2s; }
.btn-sm:hover { background: #3f3f46; }
.btn-sm-outline { background: transparent; color: #a1a1aa; border: 1px solid #3f3f46; padding: 3px 10px; border-radius: 6px; font-size: 11px; cursor: pointer; transition: all 0.2s; }
.btn-sm-outline:hover { border-color: #3b82f6; color: #3b82f6; }
.btn-sm-outline.active { border-color: #3b82f6; color: #3b82f6; background: rgba(59,130,246,0.1); }

/* Share button states */
.btn-icon.shared { color: #3b82f6; }
.btn-icon.shared:hover { color: #60a5fa; }
.btn-icon.copied { color: #22c55e !important; }

/* ====== Settings Modal ====== */
.modal-overlay {
    display: none; position: fixed; top: 0; left: 0; width: 100%; height: 100%;
    background: rgba(0,0,0,0.6); backdrop-filter: blur(4px); -webkit-backdrop-filter: blur(4px);
    z-index: 200; align-items: center; justify-content: center;
}
.modal-overlay.show { display: flex; }
.modal {
    background: #18181b; border: 1px solid #3f3f46; border-radius: 16px;
    width: 90%; max-width: 520px; padding: 32px; position: relative;
    box-shadow: 0 25px 60px rgba(0,0,0,0.5); animation: modalIn 0.25s cubic-bezier(0.4, 0, 0.2, 1);
}
@keyframes modalIn {
    from { opacity: 0; transform: scale(0.96) translateY(8px); }
    to { opacity: 1; transform: scale(1) translateY(0); }
}
.modal h2 { font-size: 20px; margin-bottom: 4px; font-weight: 600; }
.modal .modal-subtitle { color: #71717a; font-size: 14px; margin-bottom: 24px; }
.modal .close-btn {
    position: absolute; top: 16px; right: 16px; background: none; border: none;
    color: #71717a; cursor: pointer; padding: 4px; border-radius: 6px;
    display: flex; align-items: center; justify-content: center; transition: all 0.15s;
}
.modal .close-btn:hover { background: #27272a; color: #fafafa; }
.modal .close-btn svg { width: 18px; height: 18px; }
.modal .section-title {
    font-size: 11px; color: #71717a; text-transform: uppercase;
    letter-spacing: 1px; margin-bottom: 12px; font-weight: 600;
}
.modal .user-info { margin-bottom: 24px; }
.modal .user-info .info-row { display: flex; justify-content: space-between; padding: 10px 0; border-bottom: 1px solid #27272a; font-size: 14px; }
.modal .user-info .info-label { color: #71717a; }
.modal .user-info .info-value { color: #fafafa; font-weight: 500; }

.api-key-box {
    background: linear-gradient(135deg, rgba(59,130,246,0.06), rgba(168,85,247,0.06));
    border: 1px solid #27272a; border-radius: 12px; padding: 18px; margin-bottom: 16px;
}
.api-key-display { display: flex; align-items: center; justify-content: space-between; gap: 12px; }
.api-key-value {
    font-family: 'JetBrains Mono', monospace; font-size: 22px; font-weight: 600;
    background: linear-gradient(135deg, #3b82f6, #a855f7);
    -webkit-background-clip: text; -webkit-text-fill-color: transparent; background-clip: text; letter-spacing: 3px;
}
.api-key-none { color: #71717a; font-size: 14px; font-style: italic; font-family: 'Inter', sans-serif; -webkit-text-fill-color: #71717a; }
.btn-copy {
    padding: 7px 14px; background: #27272a; border: 1px solid #3f3f46; border-radius: 8px;
    color: #a1a1aa; font-size: 12px; cursor: pointer; transition: all 0.2s; white-space: nowrap;
    font-family: 'Inter', sans-serif; font-weight: 500; display: flex; align-items: center; gap: 6px;
}
.btn-copy:hover { border-color: #3b82f6; color: #fafafa; }
.btn-copy.copied { background: rgba(34,197,94,0.1); border-color: #22c55e; color: #22c55e; }
.btn-copy svg { width: 14px; height: 14px; }
.btn-generate {
    padding: 10px 20px; border: none; border-radius: 10px; font-family: 'Inter', sans-serif;
    color: #fff; font-size: 14px; font-weight: 500; cursor: pointer; transition: all 0.2s;
    background: linear-gradient(135deg, #3b82f6, #7c3aed);
}
.btn-generate:hover { box-shadow: 0 0 20px rgba(59,130,246,0.25); transform: translateY(-1px); }
.btn-generate.regen { background: linear-gradient(135deg, #f59e0b, #d97706); }
.btn-generate.regen:hover { box-shadow: 0 0 20px rgba(245,158,11,0.25); }
.api-key-hint { margin-top: 14px; font-size: 12px; color: #71717a; line-height: 1.6; }
.api-key-hint strong { color: #a1a1aa; }
.api-key-warning { margin-top: 8px; font-size: 12px; color: #f59e0b; line-height: 1.6; }

/* ====== Confirm Dialog ====== */
.confirm-overlay {
    display: none; position: fixed; top: 0; left: 0; width: 100%; height: 100%;
    background: rgba(0,0,0,0.6); backdrop-filter: blur(4px); -webkit-backdrop-filter: blur(4px);
    z-index: 300; align-items: center; justify-content: center;
}
.confirm-overlay.show { display: flex; }
.confirm-dialog {
    background: #18181b; border: 1px solid #3f3f46; border-radius: 16px;
    width: 90%; max-width: 400px; padding: 28px;
    box-shadow: 0 25px 60px rgba(0,0,0,0.5); animation: modalIn 0.25s cubic-bezier(0.4, 0, 0.2, 1);
}
.confirm-dialog h3 { font-size: 16px; margin-bottom: 8px; color: #ef4444; font-weight: 600; display: flex; align-items: center; gap: 8px; }
.confirm-dialog h3 svg { width: 18px; height: 18px; }
.confirm-dialog p { font-size: 14px; color: #a1a1aa; margin-bottom: 24px; line-height: 1.6; }
.confirm-dialog .confirm-actions { display: flex; gap: 12px; justify-content: flex-end; }
.confirm-dialog .btn-cancel {
    padding: 9px 18px; background: #27272a; border: 1px solid #3f3f46; border-radius: 10px;
    color: #a1a1aa; font-size: 14px; cursor: pointer; font-family: 'Inter', sans-serif; font-weight: 500; transition: all 0.15s;
}
.confirm-dialog .btn-cancel:hover { border-color: #52525b; color: #fafafa; }
.confirm-dialog .btn-danger {
    padding: 9px 18px; background: #ef4444; border: none; border-radius: 10px;
    color: #fff; font-size: 14px; font-weight: 600; cursor: pointer; font-family: 'Inter', sans-serif; transition: all 0.15s;
}
.confirm-dialog .btn-danger:hover { background: #dc2626; box-shadow: 0 0 16px rgba(239,68,68,0.25); }

/* ====== Fullscreen Overlay ====== */
.chart-fullscreen-overlay { position: fixed; inset: 0; background: rgba(9,9,11,0.95); backdrop-filter: blur(8px); z-index: 1000; display: flex; align-items: center; justify-content: center; padding: 40px; }
.chart-fullscreen-container { width: 100%; height: 100%; max-width: 1400px; background: #18181b; border: 1px solid #27272a; border-radius: 12px; padding: 24px; position: relative; }
