/* ===========================================================
   RESUVIX AI - DASHBOARD STYLESHEET
   SaaS Modern Design System continuing Landing Page Theme
   =========================================================== */

/* Background Elements */
body.dashboard-body {
    min-height: 100vh;
    background: #F8FAFC;
    color: var(--text);
    overflow-x: hidden;
}

/* Floating Glass Header */
.dash-header {
    position: fixed;
    top: 20px;
    left: 50%;
    transform: translateX(-50%);
    width: min(94%, 1320px);
    z-index: 1000;
    transition: all 0.35s ease;
}

.dash-nav {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 12px 24px;
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.78);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border: 1px solid rgba(255, 255, 255, 0.8);
    box-shadow: 0 15px 35px rgba(108, 99, 255, 0.08);
}

.dash-nav-left {
    display: flex;
    align-items: center;
    gap: 16px;
}

.drawer-trigger {
    width: 42px;
    height: 42px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    background: rgba(108, 99, 255, 0.08);
    color: var(--primary);
    font-size: 20px;
    transition: all 0.3s ease;
    border: 1px solid rgba(108, 99, 255, 0.15);
}

.drawer-trigger:hover {
    background: var(--primary);
    color: #ffffff;
    transform: scale(1.05);
}

.dash-logo img {
    height: 58px;
    max-height: 62px;
    width: auto;
    object-fit: contain;
    display: block;
}

.dash-nav-right {
    display: flex;
    align-items: center;
    gap: 16px;
}

.dash-badge-pro {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 6px 14px;
    border-radius: 999px;
    background: linear-gradient(135deg, #FF9F43, #FF5252);
    color: #fff;
    font-weight: 700;
    font-size: 12px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    box-shadow: 0 4px 15px rgba(255, 159, 67, 0.3);
}

.dash-badge-free {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 6px 14px;
    border-radius: 999px;
    background: rgba(108, 99, 255, 0.12);
    color: var(--primary);
    font-weight: 700;
    font-size: 12px;
    border: 1px solid rgba(108, 99, 255, 0.2);
}

.icon-btn-wrap {
    position: relative;
}

.dash-icon-btn {
    width: 42px;
    height: 42px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    background: #ffffff;
    color: var(--text-light);
    font-size: 20px;
    border: 1px solid var(--border);
    transition: all 0.3s ease;
    box-shadow: var(--shadow-sm);
}

.dash-icon-btn:hover {
    color: var(--primary);
    border-color: var(--primary);
    transform: translateY(-2px);
}

.unread-dot {
    position: absolute;
    top: 2px;
    right: 2px;
    width: 10px;
    height: 10px;
    background: #EF4444;
    border-radius: 50%;
    border: 2px solid #ffffff;
}

/* Notifications Dropdown Panel */
.notif-dropdown-menu {
    position: absolute;
    top: 52px;
    right: 0;
    width: 360px;
    max-width: 90vw;
    background: rgba(255, 255, 255, 0.96);
    backdrop-filter: blur(25px);
    -webkit-backdrop-filter: blur(25px);
    border: 1px solid rgba(226, 232, 240, 0.9);
    border-radius: 20px;
    box-shadow: 0 20px 50px rgba(15, 23, 42, 0.15);
    padding: 16px;
    z-index: 1500;
    display: none;
    flex-direction: column;
    gap: 12px;
    animation: dropdownFadeDown 0.25s cubic-bezier(0.16, 1, 0.3, 1) forwards;
}

@keyframes dropdownFadeDown {
    from {
        opacity: 0;
        transform: translateY(-10px) scale(0.96);
    }
    to {
        opacity: 1;
        transform: translateY(0) scale(1);
    }
}

.notif-dropdown-menu.show {
    display: flex;
}

.notif-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding-bottom: 12px;
    border-bottom: 1px solid var(--border);
}

.notif-header h4 {
    font-size: 15px;
    font-weight: 800;
    color: var(--text);
    display: flex;
    align-items: center;
    gap: 8px;
    margin: 0;
}

.btn-mark-read {
    background: none;
    border: none;
    font-size: 12px;
    font-weight: 700;
    color: var(--primary);
    cursor: pointer;
    transition: all 0.2s ease;
}

.btn-mark-read:hover {
    color: var(--primary-dark);
    text-decoration: underline;
}

.notif-list {
    display: flex;
    flex-direction: column;
    gap: 10px;
    max-height: 320px;
    overflow-y: auto;
}

.notif-item {
    display: flex;
    gap: 12px;
    align-items: flex-start;
    padding: 12px;
    border-radius: 14px;
    background: rgba(248, 250, 252, 0.8);
    border: 1px solid rgba(226, 232, 240, 0.8);
    transition: all 0.2s ease;
}

.notif-item:hover {
    background: rgba(108, 99, 255, 0.04);
    border-color: rgba(108, 99, 255, 0.2);
}

.notif-icon {
    width: 36px;
    height: 36px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 18px;
    flex-shrink: 0;
}

.notif-icon.purple { background: rgba(108, 99, 255, 0.12); color: #6C63FF; }
.notif-icon.green { background: rgba(34, 197, 94, 0.12); color: #22C55E; }
.notif-icon.cyan { background: rgba(6, 182, 212, 0.12); color: #06B6D4; }
.notif-icon.amber { background: rgba(245, 158, 11, 0.12); color: #F59E0B; }

.notif-content {
    flex: 1;
}

.notif-title {
    font-size: 13px;
    font-weight: 700;
    color: var(--text);
    margin-bottom: 2px;
}

.notif-text {
    font-size: 12px;
    color: var(--text-light);
    line-height: 1.4;
}

.notif-time {
    font-size: 11px;
    color: var(--text-muted);
    margin-top: 4px;
}

.user-profile-menu {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 4px 12px 4px 4px;
    border-radius: 999px;
    background: #ffffff;
    border: 1px solid var(--border);
    cursor: pointer;
    transition: all 0.3s ease;
}

.user-profile-menu:hover {
    border-color: var(--primary);
    box-shadow: var(--shadow-sm);
}

.user-avatar-small {
    width: 34px;
    height: 34px;
    border-radius: 50%;
    background: linear-gradient(135deg, var(--primary), var(--accent));
    color: #ffffff;
    font-weight: 700;
    font-size: 14px;
    display: flex;
    align-items: center;
    justify-content: center;
    object-fit: cover;
}

.user-name-abbr {
    font-weight: 600;
    font-size: 14px;
    color: var(--text);
}

/* ChatGPT Style Slide Drawer */
.drawer-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    background: rgba(15, 23, 42, 0.4);
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
    z-index: 1100;
    opacity: 0;
    visibility: hidden;
    transition: all 0.35s ease;
}

.drawer-overlay.active {
    opacity: 1;
    visibility: visible;
}

.chatgpt-drawer {
    position: fixed;
    top: 0;
    left: -320px;
    width: 320px;
    height: 100vh;
    background: rgba(255, 255, 255, 0.98);
    backdrop-filter: blur(25px);
    -webkit-backdrop-filter: blur(25px);
    border-right: 1px solid rgba(226, 232, 240, 0.9);
    box-shadow: 10px 0 40px rgba(15, 23, 42, 0.12);
    z-index: 1200;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    padding: 24px 20px 24px 20px;
    overflow: hidden;
    transition: all 0.4s cubic-bezier(0.16, 1, 0.3, 1);
}

.chatgpt-drawer.active {
    left: 0;
}

.drawer-top {
    display: flex;
    flex-direction: column;
    gap: 20px;
    flex: 1;
    overflow-y: auto;
    padding-right: 4px;
}

.drawer-brand {
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.drawer-brand .logo img {
    height: 44px;
    width: auto;
}

.drawer-close {
    width: 36px;
    height: 36px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    background: var(--surface-2);
    color: var(--text-light);
    font-size: 20px;
    transition: all 0.2s ease;
    border: none;
    cursor: pointer;
}

.drawer-close:hover {
    background: #EF4444;
    color: #ffffff;
}

.drawer-menu-list {
    display: flex;
    flex-direction: column !important;
    gap: 6px;
    width: 100%;
}

.drawer-item {
    display: flex;
    align-items: center;
    gap: 14px;
    padding: 12px 16px;
    border-radius: 16px;
    font-weight: 600;
    font-size: 14.5px;
    color: var(--text-light);
    transition: all 0.25s ease;
    text-decoration: none;
    width: 100%;
    box-sizing: border-box;
    white-space: nowrap;
}

#navItemAdmin, #dropBtnAdmin {
    display: none;
}

.drawer-item i {
    font-size: 20px;
    color: var(--text-muted);
    transition: color 0.25s ease;
}

.drawer-item:hover,
.drawer-item.active {
    background: linear-gradient(135deg, rgba(108, 99, 255, 0.1), rgba(6, 182, 212, 0.08));
    color: var(--primary);
}

.drawer-item:hover i,
.drawer-item.active i {
    color: var(--primary);
}

.drawer-bottom {
    margin-top: auto;
    padding-top: 16px;
    border-top: 1px solid rgba(226, 232, 240, 0.9);
    display: flex;
    flex-direction: column;
    gap: 12px;
    background: rgba(255, 255, 255, 0.98);
    position: relative;
    z-index: 10;
}

.user-dropdown-menu {
    position: absolute;
    top: 50px;
    right: 0;
    width: 200px;
    background: rgba(255, 255, 255, 0.98);
    backdrop-filter: blur(25px);
    -webkit-backdrop-filter: blur(25px);
    border: 1px solid rgba(226, 232, 240, 0.9);
    border-radius: 18px;
    padding: 8px;
    box-shadow: 0 15px 35px rgba(15, 23, 42, 0.15);
    display: none !important;
    flex-direction: column;
    gap: 4px;
    z-index: 1500;
}

.user-dropdown-menu.show {
    display: flex !important;
}

.dropdown-item-btn {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 10px 14px;
    border-radius: 12px;
    font-weight: 600;
    font-size: 13.5px;
    color: var(--text);
    background: none;
    border: none;
    cursor: pointer;
    width: 100%;
    text-align: left;
    transition: all 0.2s ease;
}

.dropdown-item-btn:hover {
    background: rgba(108, 99, 255, 0.08);
    color: var(--primary);
}

.drawer-pro-card {
    background: linear-gradient(135deg, var(--primary), var(--secondary));
    border-radius: 20px;
    padding: 16px 18px;
    color: #ffffff;
    box-shadow: 0 10px 30px rgba(108, 99, 255, 0.3);
}

.drawer-pro-card h4 {
    font-size: 15px;
    margin-bottom: 4px;
}

.drawer-pro-card p {
    color: rgba(255, 255, 255, 0.85);
    font-size: 12px;
    margin-bottom: 12px;
}

.btn-drawer-upgrade {
    width: 100%;
    padding: 9px 16px;
    background: #ffffff;
    color: var(--primary);
    font-weight: 700;
    font-size: 12.5px;
    border-radius: 999px;
    text-align: center;
    display: block;
    transition: transform 0.2s ease;
}

.btn-drawer-upgrade:hover {
    transform: translateY(-2px);
}

/* Dashboard Main Layout */
.dash-main {
    padding-top: 110px;
    padding-bottom: 80px;
}

.dash-container {
    width: min(94%, 1320px);
    margin: 0 auto;
}

/* Dynamic Greeting Section */
.dash-welcome {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 36px;
    flex-wrap: wrap;
    gap: 20px;
}

.dash-welcome-text h1 {
    font-size: 2.2rem;
    letter-spacing: -0.5px;
    font-weight: 800;
    margin-bottom: 4px;
}

.dash-welcome-text p {
    color: var(--text-light);
    font-size: 1.05rem;
}

.dash-actions-row {
    display: flex;
    gap: 14px;
}

/* Glass Card Grid */
.stats-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 24px;
    margin-bottom: 40px;
}

.stat-card {
    background: rgba(255, 255, 255, 0.75);
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
    border: 1px solid rgba(255, 255, 255, 0.8);
    border-radius: 24px;
    padding: 24px;
    box-shadow: 0 10px 30px rgba(15, 23, 42, 0.04);
    display: flex;
    align-items: center;
    gap: 20px;
    transition: all 0.35s ease;
}

.stat-card:hover {
    transform: translateY(-6px);
    box-shadow: 0 20px 45px rgba(108, 99, 255, 0.1);
    border-color: rgba(108, 99, 255, 0.3);
}

.stat-icon {
    width: 58px;
    height: 58px;
    border-radius: 18px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 26px;
    flex-shrink: 0;
}

.stat-icon.purple {
    background: linear-gradient(135deg, rgba(108, 99, 255, 0.15), rgba(79, 70, 229, 0.15));
    color: var(--primary);
}

.stat-icon.cyan {
    background: linear-gradient(135deg, rgba(6, 182, 212, 0.15), rgba(59, 130, 246, 0.15));
    color: var(--accent);
}

.stat-icon.green {
    background: linear-gradient(135deg, rgba(34, 197, 94, 0.15), rgba(16, 185, 129, 0.15));
    color: var(--success);
}

.stat-icon.amber {
    background: linear-gradient(135deg, rgba(245, 158, 11, 0.15), rgba(217, 119, 6, 0.15));
    color: var(--warning);
}

.stat-info span {
    font-size: 13px;
    font-weight: 600;
    color: var(--text-light);
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.stat-info h2 {
    font-size: 1.8rem;
    font-weight: 800;
    line-height: 1.2;
    margin-top: 2px;
}

.stat-info p {
    font-size: 12px;
    margin-top: 4px;
    font-weight: 600;
}

/* Quick Actions Section */
.quick-actions-section {
    margin-bottom: 40px;
}

.section-head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 20px;
}

.section-head h3 {
    font-size: 1.4rem;
    font-weight: 800;
    letter-spacing: -0.3px;
}

.actions-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
    gap: 20px;
}

.action-card {
    background: #ffffff;
    border: 1px solid var(--border);
    border-radius: 24px;
    padding: 24px;
    transition: all 0.35s ease;
    cursor: pointer;
    position: relative;
    overflow: hidden;
}

.action-card::before {
    content: "";
    position: absolute;
    top: 0;
    left: 0;
    width: 4px;
    height: 100%;
    background: var(--primary);
    opacity: 0;
    transition: opacity 0.3s ease;
}

.action-card:hover {
    transform: translateY(-5px);
    box-shadow: var(--shadow-lg);
    border-color: rgba(108, 99, 255, 0.3);
}

.action-card:hover::before {
    opacity: 1;
}

.action-card-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 16px;
}

.action-badge {
    padding: 4px 10px;
    border-radius: 999px;
    font-size: 11px;
    font-weight: 700;
    text-transform: uppercase;
}

.action-badge.free {
    background: rgba(34, 197, 94, 0.12);
    color: var(--success);
}

.action-badge.ai {
    background: rgba(108, 99, 255, 0.12);
    color: var(--primary);
}

.action-card h4 {
    font-size: 1.15rem;
    margin-bottom: 8px;
}

.action-card p {
    font-size: 0.9rem;
    color: var(--text-light);
    line-height: 1.5;
}

/* Resumes List Section */
.recent-resumes-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
    gap: 24px;
}

.resume-card {
    background: #ffffff;
    border: 1px solid var(--border);
    border-radius: 24px;
    padding: 24px;
    transition: all 0.35s ease;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    position: relative;
}

.resume-card:hover {
    transform: translateY(-6px);
    box-shadow: var(--shadow);
    border-color: var(--primary);
}

.resume-card-top {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    margin-bottom: 16px;
}

.resume-file-icon {
    width: 48px;
    height: 48px;
    border-radius: 16px;
    background: rgba(108, 99, 255, 0.1);
    color: var(--primary);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 22px;
}

.ats-score-badge {
    padding: 6px 12px;
    border-radius: 999px;
    font-size: 12px;
    font-weight: 700;
    background: rgba(34, 197, 94, 0.12);
    color: var(--success);
    display: inline-flex;
    align-items: center;
    gap: 4px;
}

.resume-title {
    font-weight: 700;
    font-size: 1.1rem;
    color: var(--text);
    margin-bottom: 4px;
}

.resume-updated {
    font-size: 12px;
    color: var(--text-muted);
    margin-bottom: 20px;
}

.resume-card-actions {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding-top: 16px;
    border-top: 1px solid var(--border);
}

.btn-action-small {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    font-size: 13px;
    font-weight: 700;
    color: var(--primary);
    padding: 6px 12px;
    border-radius: 8px;
    transition: background 0.2s ease;
}

.btn-action-small:hover {
    background: rgba(108, 99, 255, 0.1);
}

.resume-menu-btn {
    width: 32px;
    height: 32px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--text-light);
    font-size: 18px;
    transition: background 0.2s ease;
}

.resume-menu-btn:hover {
    background: var(--surface-2);
}

/* Empty Resumes Placeholder Card */
.empty-resumes-card {
    grid-column: 1 / -1;
    background: rgba(255, 255, 255, 0.7);
    border: 2px dashed var(--border);
    border-radius: 28px;
    padding: 60px 20px;
    text-align: center;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
}

.empty-icon {
    width: 72px;
    height: 72px;
    border-radius: 50%;
    background: rgba(108, 99, 255, 0.1);
    color: var(--primary);
    font-size: 32px;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 20px;
}

/* Premium Modal Glass Styling */
.modal-overlay {
    position: fixed;
    inset: 0;
    z-index: 2000;
    background: rgba(15, 23, 42, 0.65);
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    visibility: hidden;
    transition: all 0.35s ease;
    padding: 20px;
    overflow-y: auto;
    overscroll-behavior: contain;
}

/* Hide scrollbars on modals while preserving smooth scroll */
.modal-overlay::-webkit-scrollbar,
.premium-modal::-webkit-scrollbar,
#billingTransactionsList::-webkit-scrollbar {
    width: 0px !important;
    height: 0px !important;
    display: none !important;
}

.modal-overlay,
.premium-modal,
#billingTransactionsList {
    scrollbar-width: none !important;
    -ms-overflow-style: none !important;
}

.modal-overlay.active {
    opacity: 1;
    visibility: visible;
}

.premium-modal {
    width: min(100%, 640px);
    max-height: 88vh;
    overflow-y: auto;
    overscroll-behavior: contain;
    background: rgba(255, 255, 255, 0.98);
    backdrop-filter: blur(25px);
    -webkit-backdrop-filter: blur(25px);
    border: 1px solid rgba(255, 255, 255, 0.9);
    border-radius: 28px;
    padding: 32px 28px;
    box-shadow: 0 25px 60px rgba(15, 23, 42, 0.25);
    position: relative;
    transform: scale(0.92);
    transition: transform 0.35s cubic-bezier(0.16, 1, 0.3, 1);
}

.modal-overlay.active .premium-modal {
    transform: scale(1);
}

.modal-close-btn {
    position: absolute;
    top: 24px;
    right: 24px;
    width: 36px;
    height: 36px;
    border-radius: 50%;
    background: var(--surface-2);
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--text-light);
    font-size: 20px;
    transition: all 0.2s ease;
}

.modal-close-btn:hover {
    background: #EF4444;
    color: #ffffff;
}

.premium-modal-header {
    text-align: center;
    margin-bottom: 28px;
}

.premium-icon-badge {
    width: 64px;
    height: 64px;
    border-radius: 20px;
    background: linear-gradient(135deg, #FF9F43, #FF5252);
    color: #ffffff;
    font-size: 30px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 16px;
    box-shadow: 0 10px 25px rgba(255, 159, 67, 0.35);
}

.premium-modal-header h2 {
    font-size: 1.8rem;
    font-weight: 800;
    margin-bottom: 8px;
}

.premium-modal-header p {
    font-size: 0.95rem;
    color: var(--text-light);
}

.plans-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 16px;
    margin-bottom: 24px;
}

.plan-card-option {
    border: 2px solid var(--border);
    border-radius: 20px;
    padding: 18px;
    cursor: pointer;
    transition: all 0.25s ease;
    position: relative;
}

.plan-card-option.active,
.plan-card-option:hover {
    border-color: var(--primary);
    background: rgba(108, 99, 255, 0.05);
}

.plan-card-option.active::after {
    content: "✓";
    position: absolute;
    top: 12px;
    right: 14px;
    font-weight: 800;
    color: var(--primary);
}

.plan-name {
    font-weight: 700;
    font-size: 14px;
    color: var(--text);
}

.plan-price {
    font-weight: 800;
    font-size: 1.4rem;
    color: var(--primary);
    margin-top: 4px;
}

.coupon-box-row {
    display: flex;
    gap: 10px;
    margin-bottom: 24px;
}

.coupon-input {
    flex: 1;
    padding: 12px 18px;
    border-radius: 999px;
    border: 1px solid var(--border);
    font-family: inherit;
    font-size: 14px;
    outline: none;
    transition: border-color 0.2s ease;
}

.coupon-input:focus {
    border-color: var(--primary);
}

/* Responsive adjustments */
@media (max-width: 768px) {
    .dash-header {
        width: 96%;
        top: 10px;
    }
    
    .dash-nav {
        padding: 8px 12px;
    }

    .dash-nav-left {
        gap: 8px;
    }

    .dash-logo img {
        height: 34px;
    }

    .dash-nav-right {
        gap: 8px;
    }

    .dash-badge-free, .dash-badge-pro {
        padding: 4px 8px;
        font-size: 10.5px;
        white-space: nowrap;
    }

    .user-name-abbr {
        display: none;
    }

    .dash-welcome {
        flex-direction: column;
        align-items: flex-start;
    }
    
    .plans-grid {
        grid-template-columns: 1fr;
    }
    
    .premium-modal {
        padding: 28px 20px;
    }
}

