/* Dashboard Professional Design System */
:root {
    --dash-bg: #f8fafc;
    --card-bg: #ffffff;
    --muted: #64748b;
    --text-dark: #0f172a;
    --text-body: #334155;
    --border-light: #e2e8f0;
    --border-lighter: #f1f5f9;
    --primary: #6366f1;
    --primary-light: #818cf8;
    --primary-dark: #4f46e5;
    --success: #10b981;
    --warning: #f59e0b;
    --danger: #ef4444;
    --brand: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    --shadow-sm: 0 1px 2px 0 rgba(0, 0, 0, 0.05);
    --shadow-md: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -2px rgba(0, 0, 0, 0.1);
    --radius-sm: 6px;
    --radius-md: 10px;
    --radius-lg: 14px;
}

/* LAYOUT */
.dashboard-container { background: var(--dash-bg); min-height: 100vh; padding: 100px 0 80px; }
.dashboard-header { margin-bottom: 2rem; }
.dashboard-header h1 { font-size: 1.75rem; font-weight: 700; color: var(--text-dark); margin: 0 0 0.5rem; }
.dashboard-header p { margin: 0; font-size: 0.95rem; }
.dashboard-grid { display: grid; grid-template-columns: 240px 1fr; gap: 2.5rem; align-items: start; }
.dashboard-main { min-width: 0; }

/* SIDEBAR */
.dashboard-side-nav { position: sticky; top: 100px; }
.dashboard-side-nav .side-brand { font-weight: 700; padding: 0 0 1.25rem; font-size: 0.8rem; color: var(--muted); text-transform: uppercase; letter-spacing: 0.05em; border-bottom: 1px solid var(--border-light); margin-bottom: 1rem; }
.side-menu { list-style: none; padding: 0; margin: 0; display: flex; flex-direction: column; gap: 0.25rem; }
.side-item { display: flex; align-items: center; gap: 0.75rem; width: 100%; text-align: left; padding: 0.75rem 1rem; border-radius: var(--radius-md); background: transparent; border: none; color: var(--muted); cursor: pointer; font-weight: 500; font-size: 0.9rem; transition: all 0.15s ease; text-decoration: none; }
.side-item svg { width: 18px; height: 18px; opacity: 0.7; flex-shrink: 0; }
.side-item:hover { background: rgba(99, 102, 241, 0.06); color: var(--text-dark); }
.side-item.active { background: rgba(99, 102, 241, 0.1); color: var(--primary); font-weight: 600; }
.side-item.active svg { opacity: 1; }

/* CARDS */
.card { background: var(--card-bg); border-radius: var(--radius-lg); box-shadow: var(--shadow-sm); border: 1px solid var(--border-light); margin-bottom: 1.5rem; overflow: visible; }
.card-header { padding: 1.25rem 1.5rem; border-bottom: 1px solid var(--border-lighter); display: flex; justify-content: space-between; align-items: center; gap: 1rem; }
.card-header h3 { margin: 0; font-size: 1rem; font-weight: 600; color: var(--text-dark); }
.card-body { padding: 1.5rem; }
.card--padded { padding: 1.5rem; }
.card h3, .card h4 { font-size: 1rem; font-weight: 600; color: var(--text-dark); margin: 0 0 0.25rem; }
.card h4 + .muted, .card h3 + .muted { margin-top: 0; }

/* BUTTONS */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 0.5rem; padding: 0.625rem 1.125rem; border-radius: var(--radius-md); font-weight: 600; font-size: 0.875rem; cursor: pointer; transition: all 0.15s ease; text-decoration: none; line-height: 1.4; border: none; }
.btn-primary { background: linear-gradient(135deg, var(--primary) 0%, var(--primary-dark) 100%); color: #fff; box-shadow: 0 2px 4px rgba(99, 102, 241, 0.25); }
.btn-primary:hover { box-shadow: 0 4px 8px rgba(99, 102, 241, 0.35); transform: translateY(-1px); }
.btn-outline { background: #fff; border: 1px solid var(--border-light); color: var(--text-dark); }
/* .btn-outline:hover { background: var(--dash-bg); border-color: var(--primary-light); } */
.btn-sm { padding: 0.4rem 0.75rem; font-size: 0.8rem; border-radius: var(--radius-sm); }
.btn-block { width: 100%; }
.btn-text { color: var(--primary); font-weight: 600; text-decoration: none; background: none; border: none; padding: 0; cursor: pointer; }
.btn-text:hover { text-decoration: underline; }

/* FORMS */
.form-row { margin-bottom: 1rem; }
.form-row:last-child { margin-bottom: 0; }
.form-row label { display: block; margin-bottom: 0.5rem; font-weight: 600; font-size: 0.875rem; color: var(--text-dark); }
.form-control { width: 100%; padding: 0.75rem 1rem; border-radius: var(--radius-md); border: 1px solid var(--border-light); background: #fff; color: var(--text-dark); font-size: 0.9375rem; transition: border-color 0.15s ease, box-shadow 0.15s ease; font-family: inherit; }
.form-control:focus { outline: none; border-color: var(--primary); box-shadow: 0 0 0 3px rgba(99, 102, 241, 0.12); }
.form-control::placeholder { color: #94a3b8; }
textarea.form-control { resize: vertical; min-height: 100px; line-height: 1.5; }
select.form-control { cursor: pointer; appearance: none; background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 12 12'%3E%3Cpath fill='%2364748b' d='M6 8L1 3h10z'/%3E%3C/svg%3E"); background-repeat: no-repeat; background-position: right 1rem center; padding-right: 2.5rem; }
.form-grid-2 { display: grid; grid-template-columns: 1fr 1fr; gap: 1rem; }

/* TABLES */
.invoice-table { width: 100%; border-collapse: collapse; font-size: 0.9rem; }
.invoice-table th { text-align: left; padding: 1rem 1.25rem; background: var(--dash-bg); color: var(--muted); font-weight: 600; font-size: 0.8rem; text-transform: uppercase; letter-spacing: 0.025em; border-bottom: 1px solid var(--border-light); }
.invoice-table td { padding: 1rem 1.25rem; border-bottom: 1px solid var(--border-lighter); color: var(--text-body); vertical-align: middle; }
.invoice-table tr:last-child td { border-bottom: none; }
.invoice-table tr:hover td { background: rgba(99, 102, 241, 0.02); }
.invoice-status-paid { color: var(--success); font-weight: 600; }
.invoice-status-pending { color: var(--warning); font-weight: 600; }
.invoice-actions { display: flex; gap: 0.5rem; justify-content: flex-end; align-items: center; }

/* SHORTCUTS TABLE */
.shortcuts-table { width: 100%; border-collapse: collapse; font-size: 0.9rem; }
.shortcuts-table th { text-align: left; padding: 0.875rem 1rem; color: var(--muted); font-weight: 600; font-size: 0.8rem; text-transform: uppercase; letter-spacing: 0.025em; border-bottom: 2px solid var(--border-light); }
.shortcuts-table td { padding: 0.875rem 1rem; border-bottom: 1px solid var(--border-lighter); color: var(--text-body); vertical-align: top; }
.shortcuts-table tr:last-child td { border-bottom: none; }
.shortcuts-header { display: flex; justify-content: space-between; align-items: center; margin-bottom: 0.5rem; }
.shortcuts-header h4 { margin: 0; }
.shortcuts-table-container { margin-top: 1rem; border: 1px solid var(--border-lighter); border-radius: var(--radius-md); overflow: hidden; }
.pagination-controls { display: flex; gap: 0.5rem; align-items: center; justify-content: center; padding: 1rem 0 0; }

/* BADGES */
.badge { display: inline-flex; align-items: center; padding: 0.35rem 0.75rem; border-radius: 50px; font-size: 0.7rem; font-weight: 600; text-transform: uppercase; letter-spacing: 0.03em; }
.badge-pro { background: #dbeafe; color: #1d4ed8; }
.badge-free { background: #f1f5f9; color: var(--muted); }
.badge-warning { background: #fef3c7; color: #b45309; }
.badge-success { background: #d1fae5; color: #047857; }

/* ALERTS */
.alert { padding: 1rem 1.25rem; border-radius: var(--radius-md); margin-bottom: 1.5rem; font-weight: 500; font-size: 0.9rem; display: flex; align-items: center; gap: 0.75rem; }
.alert-success { background: #ecfdf5; border: 1px solid #a7f3d0; color: #065f46; }
.alert-error, .alert-danger { background: #fef2f2; border: 1px solid #fecaca; color: #991b1b; }
.alert-warning { background: #fffbeb; border: 1px solid #fde68a; color: #92400e; }
.alert-info { background: #eff6ff; border: 1px solid #bfdbfe; color: #1e40af; }

/* SUBSCRIPTION PANEL */
.current-plan { margin: 1.25rem 0; padding: 1rem 1.25rem; background: linear-gradient(135deg, rgba(99, 102, 241, 0.08) 0%, rgba(139, 92, 246, 0.08) 100%); border-radius: var(--radius-md); border-left: 3px solid var(--primary); }
.current-plan strong { font-size: 1.1rem; color: var(--text-dark); display: block; margin-bottom: 0.25rem; }
.subscription-actions { display: flex; gap: 0.75rem; margin-top: 1.25rem; flex-wrap: wrap; }
.recent-invoices { margin-top: 1.75rem; padding-top: 1.5rem; border-top: 1px solid var(--border-lighter); }
.recent-invoices h5 { font-size: 0.9rem; font-weight: 600; color: var(--text-dark); margin: 0 0 1rem; }
.invoice-list { list-style: none; padding: 0; margin: 0; }
.invoice-item { display: flex; justify-content: space-between; align-items: center; padding: 0.875rem 0; border-bottom: 1px solid var(--border-lighter); gap: 1rem; }
.invoice-item:last-child { border-bottom: none; }
.invoice-meta { flex: 1; min-width: 0; }
.invoice-plan { font-weight: 600; color: var(--text-dark); font-size: 0.9rem; }
.invoice-date { font-size: 0.8rem; }
.invoice-item .invoice-actions { display: flex; align-items: center; gap: 0.75rem; }
.invoice-amount { font-weight: 700; color: var(--text-dark); font-size: 0.9rem; }
.invoice-status { font-size: 0.8rem; }

/* OVERVIEW & PLAN CARD */
.plan-card { border: 1px solid rgba(99, 102, 241, 0.1); }
.plan-card .stat-row { display: flex; gap: 1rem; margin-top: 1.25rem; }
.plan-card .stat-box { flex: 1; text-align: center; background: var(--dash-bg); padding: 1.25rem 1rem; border-radius: var(--radius-md); border: 1px solid var(--border-lighter); }
.plan-card .stat-box label { color: var(--muted); display: block; margin-bottom: 0.5rem; font-size: 0.8rem; font-weight: 500; }
.plan-card .stat-box strong { font-size: 1.5rem; color: var(--text-dark); }
.plan-card .progress-bar { height: 6px; background: var(--border-light); border-radius: 999px; overflow: hidden; margin-top: 0.75rem; }
.plan-card .progress-fill { height: 100%; background: linear-gradient(90deg, var(--primary), #06b6d4); border-radius: 999px; transition: width 0.4s ease; }
.overview-actions { display: flex; gap: 0.75rem; margin-top: 1.25rem; flex-wrap: wrap; }
.current-plan-meta { margin-top: 1.25rem; color: var(--muted); font-size: 0.9rem; line-height: 1.6; }
.signout-row { margin-top: 1.25rem; padding-top: 1.25rem; border-top: 1px solid var(--border-lighter); }

/* ACTIVITY CARD */
.activity-card .activity-list { list-style: none; padding: 0; margin: 0; }
.activity-card .activity-info { display: flex; justify-content: space-between; gap: 1rem; align-items: center; padding: 0.75rem 0; }
.activity-card .activity-info strong { font-weight: 600; color: var(--text-dark); font-size: 0.9rem; }
.activity-card .activity-info span { color: var(--muted); font-size: 0.85rem; }

/* HELP & PROFILE CARDS */
.help-card { text-align: center; padding: 2rem 1.5rem; }
.help-card h4 { margin: 0 0 0.5rem; font-size: 1rem; }
.help-card p { margin: 0 0 1.25rem; color: var(--muted); font-size: 0.9rem; }
.profile-card { text-align: center; padding: 1.5rem; }
.profile-card .avatar-circle { width: 72px; height: 72px; border-radius: 50%; display: flex; align-items: center; justify-content: center; background: var(--brand); color: #fff; font-size: 1.5rem; font-weight: 700; margin: 0 auto 1rem; }

/* SHORTCUTS & PROMPTS PANELS */
#shortcuts-create-view, #prompts-create-view { padding: 1.5rem; background: var(--dash-bg); border-radius: var(--radius-md); border: 1px solid var(--border-lighter); margin-top: 1.25rem; }
#prompts-create-view h5, #shortcuts-create-view h5 { margin: 0 0 1rem; font-size: 0.95rem; font-weight: 600; color: var(--text-dark); }

/* UTILITIES */
.muted { color: var(--muted); }
.small { font-size: 0.85rem; }
.text-gradient { background: var(--brand); -webkit-background-clip: text; -webkit-text-fill-color: transparent; background-clip: text; }

/* PANEL DISPLAY */
/* .dash-panel { display: none; animation: fadeIn 0.3s ease-in; }
.dash-panel.active { display: block; } */

@keyframes fadeIn {
    from { opacity: 0; transform: translateY(10px); }
    to { opacity: 1; transform: translateY(0); }
}

/* TABLE RESPONSIVE */
.table-responsive { width: 100%; overflow-x: auto; }

/* CONTACT PAGE */
.contact-hero { background: linear-gradient(135deg, #667eea 0%, #764ba2 100%); margin-top: 50px; padding: 5rem 0; text-align: center; color: white; }
.contact-hero h1 { font-size: 2.75rem; margin-bottom: 1rem; font-weight: 700; }
.contact-hero p { font-size: 1.125rem; max-width: 560px; margin: 0 auto; opacity: 0.95; line-height: 1.6; }
.contact-section { padding: 4rem 0; background: var(--dash-bg); }
.contact-cards { display: grid; grid-template-columns: repeat(auto-fit, minmax(280px, 1fr)); gap: 1.5rem; margin-bottom: 3rem; }
.contact-card { text-align: center; padding: 2rem 1.5rem; }
.contact-card-icon { width: 56px; height: 56px; background: var(--brand); border-radius: 50%; display: flex; align-items: center; justify-content: center; margin: 0 auto 1rem; }
.contact-card-icon svg { width: 26px; height: 26px; fill: white; }
.contact-card h3 { font-size: 1.05rem; margin-bottom: 0.5rem; }
.contact-card p { font-size: 0.9rem; margin: 0; }
.contact-form-card { max-width: 720px; margin: 0 auto; padding: 2.5rem; }
.contact-form-header { text-align: center; margin-bottom: 2rem; }
.contact-form-header h2 { font-size: 1.5rem; margin-bottom: 0.5rem; color: var(--text-dark); }
.contact-form-header p { color: var(--muted); font-size: 0.95rem; }
.contact-tip { background: var(--dash-bg); padding: 1rem 1.25rem; border-radius: var(--radius-md); margin: 1.25rem 0; font-size: 0.875rem; color: var(--muted); border-left: 3px solid var(--primary); }
.contact-tip strong { color: var(--text-dark); }
.contact-tip a { color: var(--primary); font-weight: 600; }

/* RESPONSIVE */
@media (max-width: 900px) {
    .dashboard-container { padding: 90px 0 60px; }
    .dashboard-grid { grid-template-columns: 1fr; gap: 0; }
    .dashboard-side-nav { position: static; order: 2; margin-top: 2rem; padding-top: 1.5rem; border-top: 1px solid var(--border-light); }
    .dashboard-side-nav .side-brand { display: none; }
    .side-menu { flex-direction: row; flex-wrap: wrap; gap: 0.5rem; justify-content: center; }
    .side-item { padding: 0.5rem 0.875rem; font-size: 0.8rem; border-radius: var(--radius-sm); }
    .dashboard-header h1 { font-size: 1.5rem; }
    .card-header { flex-direction: column; align-items: flex-start; gap: 0.75rem; }
    .invoice-table { font-size: 0.8rem; }
    .invoice-table th, .invoice-table td { padding: 0.75rem 0.625rem; }
    .invoice-actions { flex-direction: column; gap: 0.35rem; }
    .stat-row { flex-direction: column; gap: 0.75rem; }
    .overview-actions, .subscription-actions { flex-direction: column; }
    .overview-actions .btn, .subscription-actions .btn { width: 100%; }
    .form-grid-2 { grid-template-columns: 1fr; }
}

@media (max-width: 640px) {
    .dashboard-container { padding: 85px 0 50px; }
    .dashboard-header h1 { font-size: 1.35rem; }
    .dashboard-header p { font-size: 0.875rem; }
    .card { border-radius: var(--radius-md); }
    .card--padded { padding: 1.25rem; }
    .btn { padding: 0.5rem 0.875rem; font-size: 0.8rem; }
    .form-control { padding: 0.625rem 0.875rem; font-size: 0.875rem; }
    .contact-hero { padding: 3.5rem 0; }
    .contact-hero h1 { font-size: 2rem; }
    .contact-hero p { font-size: 1rem; }
    .contact-section { padding: 2.5rem 0; }
    .contact-form-card { padding: 1.5rem; }
}

