:root {
    --primary: #036666;
    --primary-light: #047a7a;
    --primary-green: #80EF80;
    --success: #10b981;
    --warning: #f59e0b;
    --error: #ef4444;
    --off-white: #f8f9fa;
    --gray-50: #f9fafb;
    --gray-100: #f3f4f6;
    --gray-200: #e5e7eb;
    --gray-300: #d1d5db;
    --gray-500: #6b7280;
    --gray-700: #374151;
    --gray-900: #111827;
    --white: #ffffff;
    --black: #000000;
    --shadow: 0 1px 3px rgba(0,0,0,0.12), 0 1px 2px rgba(0,0,0,0.08);
    --shadow-lg: 0 10px 15px -3px rgba(0,0,0,0.1), 0 4px 6px -2px rgba(0,0,0,0.05);
    --radius: 8px;
    /* Aliases for help.css compatibility */
    --primary-color: var(--primary);
    --primary-hover: var(--primary-light);
    --card-bg: var(--white);
    --border-color: var(--gray-200);
    --bg-color: var(--gray-50);
    --text-color: var(--gray-900);
    --text-muted: var(--gray-500);
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Montserrat', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    background: var(--white);
    color: var(--gray-900);
    line-height: 1.5;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
}

#app {
    flex: 1;
    display: flex;
    flex-direction: column;
}

.hidden {
    display: none !important;
}

.screen {
    flex: 1;
    display: flex;
    flex-direction: column;
}

/* Login Screen */
#login-screen {
    display: flex;
    align-items: center;
    justify-content: center;
    background: var(--primary);
    min-height: calc(100vh - 48px);
}

.login-container {
    background: var(--white);
    padding: 48px;
    border-radius: var(--radius);
    box-shadow: var(--shadow-lg);
    width: 100%;
    max-width: 400px;
    text-align: center;
}

.logo {
    margin-bottom: 32px;
}

.logo-combined {
    width: 220px;
    height: auto;
    margin-bottom: 8px;
}

.logo-with-cube {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    margin-bottom: 8px;
}

.logo-cube {
    width: 48px;
    height: 48px;
}

.logo-img {
    max-width: 180px;
    height: auto;
}

.logo p {
    color: var(--gray-500);
    font-size: 14px;
}

#login-form {
    text-align: left;
}

#login-form label {
    display: block;
    font-size: 14px;
    font-weight: 500;
    color: var(--gray-700);
    margin-bottom: 6px;
}

#login-form input {
    width: 100%;
    padding: 12px 16px;
    font-size: 16px;
    font-family: inherit;
    border: 1px solid var(--gray-300);
    border-radius: var(--radius);
    margin-bottom: 16px;
    transition: border-color 0.2s, box-shadow 0.2s;
}

#login-form input:focus {
    outline: none;
    border-color: var(--primary);
    box-shadow: 0 0 0 3px rgba(3, 102, 102, 0.1);
}

#login-form button {
    width: 100%;
    padding: 12px 24px;
    font-size: 16px;
    font-weight: 500;
    font-family: inherit;
    color: var(--white);
    background: var(--primary);
    border: none;
    border-radius: var(--radius);
    cursor: pointer;
    transition: background 0.2s;
}

#login-form button:hover {
    background: var(--primary-light);
}

#login-form button:disabled {
    background: var(--gray-300);
    cursor: not-allowed;
}

.message {
    margin-top: 16px;
    padding: 12px;
    border-radius: var(--radius);
    font-size: 14px;
}

.message:empty {
    display: none;
}

.message.success {
    background: #d1fae5;
    color: #065f46;
}

.message.error {
    background: #fee2e2;
    color: #991b1b;
}

.message a {
    color: inherit;
    font-weight: 500;
}

.message .help-text {
    font-size: 12px;
    opacity: 0.85;
}

.inline-link {
    background: none;
    border: none;
    color: inherit;
    font: inherit;
    font-weight: 500;
    text-decoration: underline;
    cursor: pointer;
    padding: 0;
}

.login-toggle {
    margin-top: 20px;
    text-align: center;
}

.toggle-link {
    background: none;
    border: none;
    color: var(--primary);
    font-family: inherit;
    font-size: 14px;
    cursor: pointer;
    text-decoration: underline;
}

.toggle-link:hover {
    color: var(--primary-light);
}

.login-help {
    margin-top: 24px;
    padding-top: 16px;
    border-top: 1px solid var(--gray-200);
}

.help-link {
    color: var(--primary);
    font-size: 14px;
    text-decoration: none;
}

.help-link:hover {
    text-decoration: underline;
}

.help-separator {
    color: var(--gray-300);
    margin: 0 8px;
}

.btn-reset {
    width: 100%;
    padding: 12px;
    background: var(--primary);
    color: white;
    border: none;
    border-radius: 8px;
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
}

.btn-reset:hover {
    background: var(--primary-dark, #035f5f);
}

.btn-reset:disabled {
    background: var(--gray-300);
    cursor: not-allowed;
}

.login-footer-link {
    margin-top: 16px;
}

.sitethreesixty-link {
    color: var(--gray-500);
    font-size: 13px;
    text-decoration: none;
}

.sitethreesixty-link:hover {
    color: var(--primary);
    text-decoration: underline;
}

#totp-form {
    text-align: left;
}

#totp-form label {
    display: block;
    font-size: 14px;
    font-weight: 500;
    color: var(--gray-700);
    margin-bottom: 6px;
}

#totp-form input[type="email"] {
    width: 100%;
    padding: 12px 16px;
    font-size: 16px;
    font-family: inherit;
    border: 1px solid var(--gray-300);
    border-radius: var(--radius);
    margin-bottom: 16px;
    transition: border-color 0.2s, box-shadow 0.2s;
}

#totp-form input[type="email"]:focus {
    outline: none;
    border-color: var(--primary);
    box-shadow: 0 0 0 3px rgba(3, 102, 102, 0.1);
}

#totp-form input[type="text"] {
    width: 100%;
    padding: 16px;
    font-size: 28px;
    font-family: monospace;
    letter-spacing: 10px;
    text-align: center;
    border: 1px solid var(--gray-300);
    border-radius: var(--radius);
    margin-bottom: 16px;
}

#totp-form input[type="text"]:focus {
    outline: none;
    border-color: var(--primary);
    box-shadow: 0 0 0 3px rgba(3, 102, 102, 0.1);
}

#totp-form button {
    width: 100%;
    padding: 16px 24px;
    font-size: 18px;
    font-weight: 600;
    font-family: inherit;
    color: var(--white);
    background: var(--primary);
    border: none;
    border-radius: var(--radius);
    cursor: pointer;
    transition: background 0.2s;
}

#totp-form button:hover {
    background: var(--primary-light);
}

#totp-form button:disabled {
    background: var(--gray-300);
    cursor: not-allowed;
}

/* Dashboard Header */
header {
    background: var(--white);
    padding: 16px 24px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    box-shadow: var(--shadow);
    position: sticky;
    top: 0;
    z-index: 100;
}

.header-left {
    display: flex;
    align-items: center;
    gap: 8px;
}

.header-cube {
    width: 32px;
    height: 32px;
}

.header-logo {
    height: 28px;
    width: auto;
}

.header-logo-combined {
    height: 32px;
    width: auto;
}

.header-center {
    flex: 1;
    display: flex;
    justify-content: center;
    align-items: center;
}

.sitethreesixty-logo {
    height: 36px;
    width: auto;
    max-width: 180px;
}

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

#client-name {
    font-size: 14px;
    color: var(--gray-500);
}

#logout-btn {
    padding: 8px 16px;
    font-size: 14px;
    font-family: inherit;
    color: var(--gray-700);
    background: var(--gray-100);
    border: 1px solid var(--gray-300);
    border-radius: var(--radius);
    cursor: pointer;
    transition: background 0.2s;
}

#logout-btn:hover {
    background: var(--gray-200);
}

/* Main Dashboard */
main {
    padding: 24px;
    max-width: 1200px;
    margin: 0 auto;
    width: 100%;
    flex: 1;
}

.dashboard-grid {
    display: grid;
    grid-template-columns: repeat(12, 1fr);
    gap: 24px;
}

.card {
    background: var(--white);
    border-radius: var(--radius);
    padding: 24px;
    box-shadow: var(--shadow);
}

.card h2 {
    font-size: 24px;
    margin-bottom: 4px;
}

.card h3 {
    font-size: 16px;
    font-weight: 600;
    color: var(--gray-700);
    margin-bottom: 16px;
}

/* Welcome Card */
.welcome-card {
    grid-column: span 8;
}

.welcome-card #company-name {
    color: var(--gray-500);
    margin-bottom: 16px;
}

/* Setup Progress Bar */
.setup-progress {
    margin-top: 8px;
}

.progress-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 8px;
}

.progress-label {
    font-size: 14px;
    font-weight: 500;
    color: var(--gray-700);
}

.progress-percent {
    font-size: 14px;
    font-weight: 600;
    color: var(--primary);
}

.progress-bar-container {
    width: 100%;
    height: 12px;
    background: var(--gray-200);
    border-radius: 6px;
    overflow: hidden;
}

.progress-bar-fill {
    height: 100%;
    background: linear-gradient(90deg, var(--primary) 0%, var(--primary-light) 100%);
    border-radius: 6px;
    transition: width 0.5s ease;
    width: 0%;
}

.progress-status {
    font-size: 13px;
    color: var(--gray-500);
    margin-top: 8px;
}

/* Quick View Card */
.quick-view-card {
    grid-column: span 8;
}

.quick-view-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    margin-bottom: 24px;
}

.quick-view-welcome h2 {
    margin-bottom: 4px;
}

.company-subtitle {
    color: var(--gray-500);
    font-size: 14px;
}

.quick-view-launch {
    display: flex;
    flex-direction: column;
    align-items: center;
    background: var(--gray-50);
    padding: 12px 20px;
    border-radius: var(--radius);
}

.launch-days {
    font-size: 32px;
    font-weight: 700;
    color: var(--primary);
    line-height: 1;
}

.launch-label {
    font-size: 12px;
    color: var(--gray-500);
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.stats-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 24px;
    padding: 20px 0;
    border-top: 1px solid var(--gray-200);
    border-bottom: 1px solid var(--gray-200);
    margin-bottom: 16px;
}

.stat-item {
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
}

.stat-value-row {
    display: flex;
    align-items: center;
    gap: 8px;
}

.stat-value {
    font-size: 36px;
    font-weight: 700;
    color: var(--gray-900);
    line-height: 1.2;
}

.stat-trend {
    font-size: 14px;
    font-weight: 500;
}

.stat-trend.up {
    color: var(--success);
}

.stat-trend.down {
    color: var(--error);
}

.stat-trend.stable {
    color: var(--gray-500);
}

.stat-label {
    font-size: 13px;
    color: var(--gray-500);
    margin-top: 4px;
}

.stat-date,
.stat-compare {
    font-size: 11px;
    color: var(--gray-500);
    margin-top: 2px;
}

/* Quick Links Card */
.quick-links-card {
    grid-column: span 4;
}

.quick-links-list {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.quick-link-item {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px;
    background: var(--gray-50);
    border-radius: var(--radius);
    text-decoration: none;
    color: var(--gray-700);
    transition: background-color 0.2s ease, color 0.2s ease;
}

.quick-link-item:hover {
    background: var(--primary);
    color: var(--white);
}

.quick-link-icon {
    font-size: 18px;
    width: 24px;
    text-align: center;
}

.quick-link-text {
    font-size: 14px;
    font-weight: 500;
}

.quick-link-item.hidden {
    display: none;
}

/* Preview Card */
.preview-card {
    grid-column: span 4;
    display: flex;
    flex-direction: column;
}

.preview-card p {
    color: var(--gray-500);
    font-size: 14px;
    margin-bottom: 16px;
    flex-grow: 1;
}

.btn-primary {
    display: inline-block;
    padding: 12px 24px;
    font-size: 14px;
    font-weight: 500;
    font-family: inherit;
    color: var(--white);
    background: var(--primary);
    border-radius: var(--radius);
    text-decoration: none;
    text-align: center;
    transition: background 0.2s;
}

.btn-primary:hover {
    background: var(--primary-light);
}

.btn-primary.btn-disabled {
    background: var(--gray-300);
    color: var(--gray-500);
    cursor: not-allowed;
    pointer-events: none;
}

/* Modules Card */
.modules-card {
    grid-column: span 6;
}

.modules-card h3 {
    color: var(--success);
    font-size: 1.25rem;
}

.modules-list {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.step-number {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 28px;
    height: 28px;
    min-width: 28px;
    border-radius: 50%;
    font-size: 13px;
    font-weight: 700;
    background: var(--gray-200);
    color: var(--gray-500);
    margin-right: 4px;
}

.step-number.step-active {
    background: var(--success);
    color: var(--white);
    box-shadow: 0 0 8px rgba(16, 185, 129, 0.4);
}

.module-item {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 12px 16px;
    background: var(--gray-50);
    border-radius: var(--radius);
    transition: box-shadow 0.3s, background 0.2s;
}

.module-item.setup-module {
    border: 2px solid var(--success);
}

/* Active module item gets green glow */
.module-item.module-link {
    background: rgba(16, 185, 129, 0.08);
    border: 2px solid var(--success);
    box-shadow: 0 0 12px rgba(16, 185, 129, 0.25);
}

.module-link {
    text-decoration: none;
    color: inherit;
    cursor: pointer;
    transition: background 0.2s, transform 0.1s, box-shadow 0.2s;
}

.module-link:hover {
    background: rgba(16, 185, 129, 0.15);
    transform: translateX(4px);
    box-shadow: 0 0 20px rgba(16, 185, 129, 0.35);
}

.module-link .module-name::after {
    content: ' →';
    color: var(--success);
    font-weight: 600;
}

/* In Progress module item gets yellow/amber glow */
.module-item.module-link-progress {
    background: rgba(245, 158, 11, 0.08);
    border: 2px solid #f59e0b;
    box-shadow: 0 0 12px rgba(245, 158, 11, 0.25);
}

.module-link-progress {
    text-decoration: none;
    color: inherit;
    cursor: pointer;
    transition: background 0.2s, transform 0.1s, box-shadow 0.2s;
}

.module-link-progress:hover {
    background: rgba(245, 158, 11, 0.15);
    transform: translateX(4px);
    box-shadow: 0 0 20px rgba(245, 158, 11, 0.35);
}

.module-link-progress .module-name::after {
    content: ' →';
    color: #f59e0b;
    font-weight: 600;
}

.module-name {
    font-weight: 500;
}

.module-status {
    font-size: 12px;
    font-weight: 500;
    padding: 4px 12px;
    border-radius: 9999px;
    text-transform: uppercase;
}

.module-status.inactive {
    background: var(--gray-200);
    color: var(--gray-500);
}

.module-status.pending {
    background: var(--gray-200);
    color: var(--gray-500);
}

.module-status.active {
    background: var(--success);
    color: var(--white);
    font-weight: 600;
}

.module-status.in_progress {
    background: #f59e0b;
    color: var(--white);
    font-weight: 600;
}

.module-status.complete {
    background: #3b82f6;
    color: var(--white);
    font-weight: 600;
}

/* Reading/Educational Links Card */
.reading-card {
    grid-column: span 6;
}

.reading-subtitle {
    color: var(--gray-500);
    font-size: 14px;
    margin-bottom: 16px;
}

.reading-list {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.reading-item {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 12px 16px;
    background: var(--gray-50);
    border-radius: var(--radius);
    border: none;
    cursor: pointer;
    font-family: inherit;
    font-size: 14px;
    text-align: left;
    transition: background 0.2s, transform 0.1s;
}

.reading-item:hover {
    background: var(--gray-100);
    transform: translateX(4px);
}

.reading-name {
    font-weight: 500;
    color: var(--gray-900);
}

.reading-arrow {
    color: var(--primary);
    font-weight: 600;
}

/* Activity Card */
.activity-card {
    grid-column: span 6;
}

.activity-feed {
    display: flex;
    flex-direction: column;
    gap: 12px;
    max-height: 180px;
    overflow-y: auto;
}

.activity-item {
    display: flex;
    gap: 12px;
    padding: 12px;
    background: var(--gray-50);
    border-radius: var(--radius);
}

.activity-icon {
    width: 32px;
    height: 32px;
    background: var(--primary);
    color: var(--white);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 14px;
    flex-shrink: 0;
}

.activity-content {
    flex-grow: 1;
}

.activity-action {
    font-weight: 500;
    margin-bottom: 2px;
}

.activity-time {
    font-size: 12px;
    color: var(--gray-500);
}

.coming-soon {
  color: #ef4444; /* red */
  font-weight: 600;
}


/* Invoice Card */
.invoice-card {
    grid-column: span 6;
}

/* Documents Card */
.documents-card {
    grid-column: span 6;
}

.documents-subtitle {
    color: var(--gray-500);
    font-size: 14px;
    margin-bottom: 16px;
}

.documents-list {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.document-item {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px 16px;
    background: var(--gray-50);
    border-radius: var(--radius);
    text-decoration: none;
    color: inherit;
    transition: background 0.2s, transform 0.2s;
}

.document-item:hover {
    background: var(--gray-100);
    transform: translateX(4px);
}

.document-icon {
    font-size: 24px;
    flex-shrink: 0;
}

.document-info {
    flex: 1;
    display: flex;
    flex-direction: column;
    gap: 2px;
}

.document-name {
    font-weight: 500;
    color: var(--gray-900);
}

.document-desc {
    font-size: 12px;
    color: var(--gray-500);
}

.download-icon {
    font-size: 18px;
    color: var(--primary);
    font-weight: bold;
    flex-shrink: 0;
}

.invoice-info {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 16px;
    background: var(--gray-50);
    border-radius: var(--radius);
}

.invoice-details {
    display: flex;
    gap: 32px;
}

.invoice-field {
    display: flex;
    flex-direction: column;
}

.invoice-label {
    font-size: 12px;
    color: var(--gray-500);
}

.invoice-value {
    font-weight: 500;
}

.invoice-status {
    font-size: 12px;
    font-weight: 500;
    padding: 4px 12px;
    border-radius: 9999px;
    text-transform: uppercase;
}

.invoice-status.paid {
    background: #d1fae5;
    color: #065f46;
}

.invoice-status.unpaid {
    background: #fef3c7;
    color: #92400e;
}

.invoice-status.overdue {
    background: #fee2e2;
    color: #991b1b;
}

/* Enhanced Invoice Card Styles */
.invoice-summary {
    padding: 16px;
    background: var(--gray-50);
    border-radius: var(--radius);
}

.invoice-header-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 8px;
}

.invoice-number {
    font-size: 13px;
    color: var(--gray-500);
    font-weight: 500;
}

.invoice-status-badge {
    font-size: 11px;
    font-weight: 600;
    padding: 3px 10px;
    border-radius: 9999px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.invoice-status-badge.paid {
    background: #d1fae5;
    color: #065f46;
}

.invoice-status-badge.unpaid {
    background: #fef3c7;
    color: #92400e;
}

.invoice-status-badge.overdue {
    background: #fee2e2;
    color: #991b1b;
}

.invoice-amount {
    font-size: 28px;
    font-weight: 700;
    color: var(--gray-900);
    margin-bottom: 4px;
}

.invoice-due-date {
    font-size: 13px;
    color: var(--gray-500);
    margin-bottom: 16px;
}

.invoice-actions {
    display: flex;
    gap: 8px;
    margin-bottom: 12px;
}

.btn-invoice {
    padding: 8px 16px;
    font-size: 13px;
    font-weight: 500;
    font-family: inherit;
    border-radius: var(--radius);
    cursor: pointer;
    text-decoration: none;
    text-align: center;
    transition: background 0.2s, transform 0.1s;
}

.btn-invoice:active {
    transform: scale(0.98);
}

.btn-download {
    background: var(--primary);
    color: var(--white);
    border: none;
}

.btn-download:hover {
    background: var(--primary-light);
}

.btn-pay {
    background: var(--success);
    color: var(--white);
    border: none;
}

.btn-pay:hover {
    background: #059669;
}

.invoice-history-link {
    display: block;
    width: 100%;
    background: none;
    border: none;
    color: var(--primary);
    font-size: 13px;
    font-family: inherit;
    cursor: pointer;
    text-align: left;
    padding: 0;
}

.invoice-history-link:hover {
    text-decoration: underline;
}

/* Invoice History Modal */
.invoice-modal-content {
    max-width: 500px;
}

.invoice-history-list {
    display: flex;
    flex-direction: column;
    gap: 12px;
    max-height: 400px;
    overflow-y: auto;
}

.invoice-history-item {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px;
    background: var(--gray-50);
    border-radius: var(--radius);
}

.invoice-history-info {
    flex: 1;
    display: flex;
    flex-direction: column;
    gap: 2px;
}

.invoice-history-number {
    font-size: 13px;
    font-weight: 500;
    color: var(--gray-900);
}

.invoice-history-period {
    font-size: 12px;
    color: var(--gray-500);
}

.invoice-history-amount {
    font-weight: 600;
    font-size: 14px;
    color: var(--gray-900);
    min-width: 70px;
    text-align: right;
}

.btn-invoice-sm {
    padding: 6px 12px;
    font-size: 12px;
    font-weight: 500;
    font-family: inherit;
    background: var(--primary);
    color: var(--white);
    border: none;
    border-radius: var(--radius);
    cursor: pointer;
    transition: background 0.2s;
}

.btn-invoice-sm:hover {
    background: var(--primary-light);
}

.loading-text,
.error-text {
    text-align: center;
    color: var(--gray-500);
    padding: 20px;
}

.error-text {
    color: var(--error);
}

/* Contact Steve Card */
.contact-card {
    grid-column: span 6;
}

.contact-subtitle {
    font-size: 13px;
    color: var(--gray-500);
    margin-bottom: 16px;
}

.contact-form {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.message-type-selector {
    display: flex;
    gap: 8px;
    flex-wrap: wrap;
}

.type-option {
    display: flex;
    align-items: center;
    cursor: pointer;
}

.type-option input[type="radio"] {
    display: none;
}

.type-label {
    padding: 6px 14px;
    font-size: 13px;
    font-weight: 500;
    background: var(--gray-100);
    border: 2px solid var(--gray-200);
    border-radius: 20px;
    color: var(--gray-600);
    transition: all 0.2s;
}

.type-option input[type="radio"]:checked + .type-label {
    background: var(--primary);
    border-color: var(--primary);
    color: var(--white);
}

.type-option:hover .type-label {
    border-color: var(--primary);
}

.contact-form textarea {
    width: 100%;
    padding: 12px;
    font-family: inherit;
    font-size: 14px;
    border: 2px solid var(--gray-200);
    border-radius: var(--radius);
    resize: vertical;
    min-height: 80px;
    transition: border-color 0.2s;
}

.contact-form textarea:focus {
    outline: none;
    border-color: var(--primary);
}

.btn-send {
    align-self: flex-start;
    padding: 10px 24px;
}

.contact-status {
    font-size: 13px;
    margin-top: 8px;
}

.contact-status.success {
    color: var(--success);
}

.contact-status.error {
    color: var(--error);
}

.no-invoice {
    color: var(--gray-500);
    font-size: 14px;
}

/* Site Footer - Sticky */
.site-footer {
    background: var(--black);
    color: var(--white);
    padding: 12px 24px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-family: 'Montserrat', sans-serif;
    font-size: 12px;
    font-weight: 400;
    opacity: 1;
    position: sticky;
    bottom: 0;
    z-index: 100;
}

.footer-left {
    display: flex;
    gap: 24px;
    align-items: center;
    opacity: 0.75;
}

.footer-brand,
.footer-copy {
    color: var(--white);
}

.footer-brand {
    display: flex;
    align-items: center;
    gap: 6px;
}

.footer-cube {
    width: 18px;
    height: 18px;
}

.footer-logo-combined {
    height: 16px;
    width: auto;
    vertical-align: middle;
}

.footer-brand .highlight,
.footer-copy .highlight {
    color: var(--primary-green);
}

.footer-right {
    display: flex;
    gap: 16px;
    align-items: center;
    opacity: 0.75;
}

.footer-link {
    background: none;
    border: none;
    color: var(--white);
    font-family: inherit;
    font-size: 12px;
    font-weight: 400;
    cursor: pointer;
    text-decoration: underline;
    transition: color 0.2s;
}

.footer-link:hover {
    color: var(--primary-green);
}

/* Modal */
.modal {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    z-index: 1000;
    display: flex;
    align-items: center;
    justify-content: center;
}

.modal-backdrop {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.5);
}

.modal-content {
    position: relative;
    background: var(--white);
    border-radius: var(--radius);
    box-shadow: var(--shadow-lg);
    max-width: 400px;
    width: 90%;
    max-height: 80vh;
    overflow-y: auto;
}

.modal-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 16px 24px;
    border-bottom: 1px solid var(--gray-200);
}

.modal-header h3 {
    font-size: 18px;
    font-weight: 600;
    margin: 0;
    color: var(--gray-900);
}

.modal-header-actions {
    display: flex;
    align-items: center;
    gap: 12px;
}

.modal-close {
    background: none;
    border: none;
    font-size: 24px;
    color: var(--gray-500);
    cursor: pointer;
    line-height: 1;
    padding: 0;
}

.modal-close:hover {
    color: var(--gray-900);
}

.modal-nav {
    padding: 16px 24px;
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.modal-nav a {
    color: var(--gray-700);
    text-decoration: none;
    font-size: 14px;
    padding: 8px 0;
    border-bottom: 1px solid var(--gray-100);
    transition: color 0.2s;
}

.modal-nav a:last-child {
    border-bottom: none;
}

.modal-nav a:hover {
    color: var(--primary);
}

/* TOTP Setup Modal */
.totp-required-backdrop {
    background: rgba(0, 0, 0, 0.8);
}

.totp-setup-content {
    max-width: 480px;
}

.totp-setup-body {
    padding: 24px;
}

.totp-setup-intro {
    margin-bottom: 24px;
    padding: 16px;
    background: #fef3c7;
    border-radius: var(--radius);
    color: #92400e;
}

.totp-setup-intro p {
    margin: 0;
    font-size: 14px;
}

.totp-setup-steps {
    display: flex;
    flex-direction: column;
    gap: 24px;
}

.totp-step {
    display: flex;
    gap: 16px;
    align-items: flex-start;
}

.step-number {
    width: 32px;
    height: 32px;
    background: var(--primary);
    color: var(--white);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 600;
    flex-shrink: 0;
}

.step-content {
    flex: 1;
}

.step-content p {
    margin: 0 0 8px 0;
    font-size: 14px;
}

.step-hint {
    color: var(--gray-500);
    font-size: 13px !important;
}

.totp-qr-container {
    margin: 16px 0;
    padding: 16px;
    background: var(--white);
    border: 1px solid var(--gray-200);
    border-radius: var(--radius);
    text-align: center;
}

.totp-qr-image {
    width: 200px;
    height: 200px;
}

.app-links {
    display: flex;
    gap: 12px;
    margin-top: 8px;
}

.app-link {
    font-size: 12px;
    color: var(--primary);
    text-decoration: none;
    padding: 6px 12px;
    border: 1px solid var(--primary);
    border-radius: var(--radius);
    transition: background 0.2s, color 0.2s;
}

.app-link:hover {
    background: var(--primary);
    color: var(--white);
}

.setup-method-tabs {
    display: flex;
    gap: 0;
    margin-bottom: 16px;
    border: 1px solid var(--gray-300);
    border-radius: var(--radius);
    overflow: hidden;
}

.method-tab {
    flex: 1;
    padding: 10px 16px;
    font-size: 13px;
    font-family: inherit;
    font-weight: 500;
    border: none;
    background: var(--gray-100);
    color: var(--gray-700);
    cursor: pointer;
    transition: background 0.2s, color 0.2s;
}

.method-tab:first-child {
    border-right: 1px solid var(--gray-300);
}

.method-tab.active {
    background: var(--primary);
    color: var(--white);
}

.method-tab:hover:not(.active) {
    background: var(--gray-200);
}

.setup-method {
    display: none;
}

.setup-method.active {
    display: block;
}

.manual-entry-instructions {
    background: var(--gray-50);
    border-radius: var(--radius);
    padding: 16px;
    margin-bottom: 16px;
}

.manual-entry-instructions ol {
    margin: 0;
    padding-left: 20px;
    font-size: 13px;
    color: var(--gray-700);
}

.manual-entry-instructions li {
    margin-bottom: 8px;
}

.manual-entry-instructions li:last-child {
    margin-bottom: 0;
}

.secret-key-box {
    background: var(--white);
    border: 1px solid var(--gray-200);
    border-radius: var(--radius);
    padding: 16px;
}

.secret-key-box label {
    display: block;
    font-size: 12px;
    font-weight: 500;
    color: var(--gray-500);
    margin-bottom: 8px;
}

.secret-copy-container {
    display: flex;
    gap: 8px;
    align-items: stretch;
}

.totp-secret {
    flex: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    font-family: monospace;
    font-size: 15px;
    letter-spacing: 2px;
    padding: 12px;
    background: var(--gray-100);
    border-radius: var(--radius);
    text-align: center;
    word-break: break-all;
    user-select: all;
}

.copy-btn {
    padding: 12px 16px;
    font-size: 13px;
    font-family: inherit;
    font-weight: 500;
    color: var(--white);
    background: var(--primary);
    border: none;
    border-radius: var(--radius);
    cursor: pointer;
    transition: background 0.2s;
    white-space: nowrap;
}

.copy-btn:hover {
    background: var(--primary-light);
}

.copy-btn:active {
    transform: scale(0.98);
}

.copy-feedback {
    margin: 8px 0 0 0;
    font-size: 12px;
    text-align: center;
}

.copy-feedback.success {
    color: #065f46;
}

.copy-feedback.error {
    color: #991b1b;
}

.totp-setup-input {
    width: 100%;
    padding: 12px 16px;
    font-size: 24px;
    font-family: monospace;
    letter-spacing: 8px;
    text-align: center;
    border: 1px solid var(--gray-300);
    border-radius: var(--radius);
    margin-bottom: 16px;
}

.totp-setup-input:focus {
    outline: none;
    border-color: var(--primary);
    box-shadow: 0 0 0 3px rgba(3, 102, 102, 0.1);
}

#totp-verify-section .btn-primary {
    width: 100%;
    margin-bottom: 12px;
}

#totp-setup-message {
    margin-top: 0;
}

/* Educational Modals */
.edu-modal-content {
    max-width: 560px;
}

.modal-body {
    padding: 24px;
    line-height: 1.7;
}

.modal-body p {
    margin-bottom: 16px;
    font-size: 15px;
    color: var(--gray-700);
}

.modal-body p:last-child {
    margin-bottom: 0;
}

.modal-body ul {
    margin: 0 0 16px 0;
    padding-left: 24px;
    color: var(--gray-700);
}

.modal-body li {
    margin-bottom: 8px;
    font-size: 15px;
}

.modal-body strong {
    color: var(--gray-900);
}

.modal-callout {
    background: rgba(4, 122, 122, 0.08);
    border-left: 4px solid var(--primary);
    padding: 16px 20px;
    margin: 20px 0 0 0;
    border-radius: 0 6px 6px 0;
}

.modal-callout p {
    margin-bottom: 12px;
    font-size: 14px;
}

.modal-callout p:last-child {
    margin-bottom: 0;
}

.modal-callout ul {
    margin-bottom: 0;
}

.modal-callout li {
    font-size: 14px;
}

/* Sites Selection Modal */
.sites-modal-content {
    max-width: 400px;
}

.sites-modal-intro {
    color: var(--gray-500);
    font-size: 14px;
    margin-bottom: 20px;
}

.sites-list {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.site-option {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 16px 20px;
    background: var(--gray-50);
    border: 1px solid var(--gray-200);
    border-radius: var(--radius);
    text-decoration: none;
    color: var(--gray-900);
    font-weight: 500;
    transition: all 0.2s ease;
}

.site-option:hover {
    background: var(--primary);
    border-color: var(--primary);
    color: var(--white);
    transform: translateY(-2px);
    box-shadow: var(--shadow);
}

.site-label {
    font-size: 15px;
}

.site-arrow {
    font-size: 18px;
    opacity: 0.6;
    transition: transform 0.2s ease;
}

.site-option:hover .site-arrow {
    opacity: 1;
    transform: translateX(4px);
}

/* Loading Overlay */
.loading {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(255, 255, 255, 0.9);
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    z-index: 1000;
}

.spinner {
    width: 40px;
    height: 40px;
    border: 3px solid var(--gray-200);
    border-top-color: var(--primary);
    border-radius: 50%;
    animation: spin 0.8s linear infinite;
}

@keyframes spin {
    to { transform: rotate(360deg); }
}

.loading p {
    margin-top: 16px;
    color: var(--gray-500);
}

/* Community Directory Card */
.community-card {
    grid-column: span 8;
}

.community-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 8px;
}

.community-header h3 {
    margin-bottom: 0;
}

.community-tabs {
    display: flex;
    gap: 4px;
    margin: 16px 0;
    border-bottom: 1px solid var(--gray-200);
    padding-bottom: 0;
}

.community-tab {
    padding: 8px 16px;
    background: none;
    border: none;
    font-size: 14px;
    font-weight: 500;
    font-family: inherit;
    color: var(--gray-500);
    cursor: pointer;
    border-bottom: 2px solid transparent;
    margin-bottom: -1px;
    transition: color 0.2s, border-color 0.2s;
}

.community-tab:hover {
    color: var(--gray-700);
}

.community-tab.active {
    color: var(--primary);
    border-bottom-color: var(--primary);
}

.community-content {
    min-height: 200px;
}

.tab-content {
    display: none;
}

.tab-content.active {
    display: block;
}

.directory-list {
    display: flex;
    flex-direction: column;
    gap: 8px;
    max-height: 300px;
    overflow-y: auto;
}

.directory-item {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 12px;
    background: var(--gray-50);
    border-radius: var(--radius);
    transition: background 0.2s;
}

.directory-item:hover {
    background: var(--gray-100);
}

.directory-item-info {
    display: flex;
    flex-direction: column;
    gap: 2px;
}

.directory-item-name {
    font-size: 14px;
    font-weight: 500;
    color: var(--gray-900);
}

.directory-item-detail {
    font-size: 12px;
    color: var(--gray-500);
}

.directory-item-actions {
    display: flex;
    gap: 8px;
    align-items: center;
}

.directory-link {
    color: var(--primary);
    font-size: 13px;
    text-decoration: none;
}

.directory-link:hover {
    text-decoration: underline;
}

/* Recommendation Item */
.recommendation-item {
    padding: 16px;
    background: var(--gray-50);
    border-radius: var(--radius);
    margin-bottom: 12px;
}

.recommendation-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    margin-bottom: 8px;
}

.recommendation-name {
    font-size: 15px;
    font-weight: 600;
    color: var(--gray-900);
}

.recommendation-category {
    font-size: 12px;
    color: var(--gray-500);
    background: var(--gray-200);
    padding: 2px 8px;
    border-radius: 12px;
}

.recommendation-contact {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
    margin: 8px 0;
    font-size: 13px;
}

.recommendation-contact a {
    color: var(--primary);
    text-decoration: none;
}

.recommendation-contact a:hover {
    text-decoration: underline;
}

.recommendation-endorsements {
    margin-top: 12px;
    padding-top: 12px;
    border-top: 1px solid var(--gray-200);
}

.endorsement-count {
    font-size: 13px;
    color: var(--gray-500);
    margin-bottom: 8px;
}

.endorsement-item {
    padding: 8px 12px;
    background: var(--white);
    border-radius: var(--radius);
    margin-bottom: 8px;
}

.endorsement-company {
    font-size: 13px;
    font-weight: 500;
    color: var(--gray-700);
}

.endorsement-testimonial {
    font-size: 13px;
    color: var(--gray-600);
    font-style: italic;
    margin-top: 4px;
}

.recommendation-actions {
    display: flex;
    gap: 8px;
    margin-top: 12px;
}

.btn-endorse {
    padding: 6px 12px;
    font-size: 12px;
    font-weight: 500;
    font-family: inherit;
    background: var(--primary);
    color: var(--white);
    border: none;
    border-radius: var(--radius);
    cursor: pointer;
    transition: background 0.2s;
}

.btn-endorse:hover {
    background: var(--primary-light);
}

.btn-withdraw {
    padding: 6px 12px;
    font-size: 12px;
    font-weight: 500;
    font-family: inherit;
    background: var(--gray-200);
    color: var(--gray-700);
    border: none;
    border-radius: var(--radius);
    cursor: pointer;
    transition: background 0.2s;
}

.btn-withdraw:hover {
    background: var(--gray-300);
}

/* Recommend Modal */
.recommend-modal-content,
.endorse-modal-content {
    max-width: 500px;
}

.recommend-intro,
.endorse-intro {
    font-size: 14px;
    color: var(--gray-600);
    margin-bottom: 20px;
}

.form-group {
    margin-bottom: 16px;
}

.form-group label {
    display: block;
    font-size: 13px;
    font-weight: 500;
    color: var(--gray-700);
    margin-bottom: 6px;
}

.form-group input,
.form-group select,
.form-group textarea {
    width: 100%;
    padding: 10px 12px;
    font-size: 14px;
    font-family: inherit;
    border: 1px solid var(--gray-300);
    border-radius: var(--radius);
    background: var(--white);
    transition: border-color 0.2s;
}

.form-group input:focus,
.form-group select:focus,
.form-group textarea:focus {
    outline: none;
    border-color: var(--primary);
}

.form-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 16px;
}

.form-actions {
    display: flex;
    justify-content: flex-end;
    gap: 12px;
    margin-top: 20px;
}

.form-status {
    margin-top: 12px;
    font-size: 13px;
}

.form-status.success {
    color: var(--success);
}

.form-status.error {
    color: var(--error);
}

/* Member Perks Card */
.perks-card {
    grid-column: span 4;
}

.perks-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 8px;
}

.perks-header h3 {
    margin-bottom: 0;
}

.perks-list {
    display: flex;
    flex-direction: column;
    gap: 12px;
    max-height: 350px;
    overflow-y: auto;
    margin: 16px 0;
}

.perk-item {
    padding: 16px;
    background: var(--gray-50);
    border-radius: var(--radius);
}

.perk-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    margin-bottom: 8px;
}

.perk-title {
    font-size: 15px;
    font-weight: 600;
    color: var(--gray-900);
    margin: 0;
}

.perk-company {
    font-size: 12px;
    color: var(--gray-500);
}

.perk-description {
    font-size: 13px;
    color: var(--gray-700);
    margin: 0 0 8px 0;
}

.perk-conditions {
    font-size: 12px;
    color: var(--warning);
    margin: 0 0 8px 0;
}

.perk-expiry {
    font-size: 11px;
    color: var(--gray-500);
    display: block;
    margin-bottom: 8px;
}

.perk-redeem {
    font-size: 12px;
    color: var(--primary);
    margin: 0;
    padding-top: 8px;
    border-top: 1px solid var(--gray-200);
}

.perk-actions {
    display: flex;
    gap: 8px;
    margin-top: 8px;
}

.perks-footer {
    text-align: center;
    padding-top: 8px;
    border-top: 1px solid var(--gray-200);
}

.btn-text {
    background: none;
    border: none;
    color: var(--primary);
    font-size: 13px;
    font-family: inherit;
    cursor: pointer;
    padding: 0;
}

.btn-text:hover {
    text-decoration: underline;
}

/* Perk Modal */
.perk-modal-content,
.my-perks-modal-content {
    max-width: 500px;
}

.perk-intro {
    font-size: 14px;
    color: var(--gray-600);
    margin-bottom: 20px;
}

/* My Perks List */
.my-perks-list {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.my-perk-item {
    padding: 16px;
    background: var(--gray-50);
    border-radius: var(--radius);
}

.my-perk-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    margin-bottom: 8px;
}

.my-perk-title {
    font-size: 14px;
    font-weight: 500;
    color: var(--gray-900);
}

.my-perk-status {
    font-size: 11px;
    padding: 2px 8px;
    border-radius: 12px;
    font-weight: 500;
}

.my-perk-status.pending {
    background: var(--warning);
    color: var(--white);
}

.my-perk-status.active {
    background: var(--success);
    color: var(--white);
}

.my-perk-status.withdrawn {
    background: var(--gray-300);
    color: var(--gray-700);
}

.my-perk-status.expired {
    background: var(--gray-300);
    color: var(--gray-700);
}

.my-perk-description {
    font-size: 13px;
    color: var(--gray-600);
    margin: 0 0 8px 0;
}

.my-perk-date {
    font-size: 11px;
    color: var(--gray-500);
}

.no-perks {
    text-align: center;
    color: var(--gray-500);
    font-size: 14px;
    padding: 20px;
}

/* =======================
   REFERRAL PROGRAM STYLES
   ======================= */

.referrals-card {
    grid-column: span 1;
}

.referral-stats {
    display: flex;
    gap: 24px;
    margin: 16px 0;
}

.referral-stats .stat-item {
    flex: 1;
    text-align: center;
    padding: 12px;
    background: var(--gray-50);
    border-radius: 8px;
}

.referral-stats .stat-value {
    font-size: 24px;
    font-weight: 700;
    color: var(--primary);
    display: block;
}

.referral-stats .stat-label {
    font-size: 12px;
    color: var(--gray-500);
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.referral-code-box {
    background: var(--primary);
    color: var(--white);
    padding: 16px;
    border-radius: 8px;
    margin: 16px 0;
}

.referral-code-label {
    font-size: 11px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    opacity: 0.8;
    display: block;
    margin-bottom: 8px;
}

.referral-code-row {
    display: flex;
    align-items: center;
    gap: 12px;
}

.referral-code {
    font-size: 20px;
    font-weight: 700;
    font-family: monospace;
    letter-spacing: 1px;
}

.btn-copy {
    background: rgba(255, 255, 255, 0.2);
    border: none;
    padding: 8px 12px;
    border-radius: 4px;
    cursor: pointer;
    transition: background 0.2s;
    font-size: 16px;
}

.btn-copy:hover {
    background: rgba(255, 255, 255, 0.3);
}

.btn-copy.copied {
    background: var(--success);
}

.referrals-list {
    margin: 16px 0;
}

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

.referral-item:last-child {
    border-bottom: none;
}

.ref-company {
    font-weight: 500;
    color: var(--gray-800);
}

.ref-status {
    font-size: 12px;
    padding: 4px 8px;
    border-radius: 4px;
    background: var(--gray-100);
    color: var(--gray-600);
}

.referral-item.pending .ref-status {
    background: var(--warning-light);
    color: var(--warning);
}

.referral-item.qualified .ref-status {
    background: var(--info-light);
    color: var(--info);
}

.referral-item.credited .ref-status {
    background: var(--success-light);
    color: var(--success);
}

.ref-amount {
    font-weight: 600;
    color: var(--primary);
}

.referral-note {
    font-size: 13px;
    color: var(--gray-500);
    line-height: 1.5;
    margin-top: 16px;
}

.no-referrals {
    text-align: center;
    color: var(--gray-500);
    font-size: 14px;
    padding: 20px;
}

.referral-code-missing {
    text-align: center;
    padding: 16px;
    background: var(--gray-50);
    border-radius: 8px;
    margin: 16px 0;
}

.referral-code-missing p {
    color: var(--gray-600);
    margin: 0;
    font-size: 14px;
}

/* =======================
   MILESTONES STYLES
   ======================= */

.milestones-card {
    grid-column: span 1;
}

.milestones-list {
    margin-top: 16px;
}

.milestone-item {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px;
    background: var(--gray-50);
    border-radius: 8px;
    margin-bottom: 8px;
    transition: transform 0.2s, box-shadow 0.2s;
}

.milestone-item:last-child {
    margin-bottom: 0;
}

.milestone-item.new {
    background: linear-gradient(135deg, #e6f2f2 0%, var(--gray-50) 100%);
    border: 1px solid var(--primary);
}

.milestone-item:hover {
    transform: translateY(-1px);
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
}

.milestone-icon {
    font-size: 24px;
    flex-shrink: 0;
}

.milestone-content {
    flex: 1;
    min-width: 0;
}

.milestone-label {
    font-weight: 600;
    color: var(--gray-800);
    display: block;
}

.milestone-date {
    font-size: 12px;
    color: var(--gray-500);
    display: block;
    margin-top: 2px;
}

.new-badge {
    background: var(--primary);
    color: var(--white);
    font-size: 10px;
    font-weight: 700;
    text-transform: uppercase;
    padding: 3px 8px;
    border-radius: 10px;
    letter-spacing: 0.5px;
    flex-shrink: 0;
    animation: pulse 2s infinite;
}

@keyframes pulse {
    0%, 100% {
        opacity: 1;
    }
    50% {
        opacity: 0.7;
    }
}

.no-milestones {
    text-align: center;
    color: var(--gray-500);
    font-size: 14px;
    padding: 20px;
}

/* =======================
   FAQ & HELP SECTION STYLES
   ======================= */

.faq-card {
    grid-column: span 6;
}

.faq-search-container {
    margin-bottom: 16px;
}

.faq-search {
    width: 100%;
    padding: 10px 14px;
    font-size: 14px;
    font-family: inherit;
    border: 1px solid var(--gray-300);
    border-radius: var(--radius);
    background: var(--gray-50);
    transition: border-color 0.2s, background-color 0.2s;
}

.faq-search:focus {
    outline: none;
    border-color: var(--primary);
    background: var(--white);
}

.faq-search::placeholder {
    color: var(--gray-500);
}

.faq-categories {
    display: flex;
    flex-direction: column;
    gap: 8px;
    max-height: 500px;
    overflow-y: auto;
}

.faq-category {
    border: 1px solid var(--gray-200);
    border-radius: var(--radius);
    overflow: hidden;
}

.faq-category.expanded {
    border-color: var(--primary);
}

.faq-category-header {
    width: 100%;
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 12px 14px;
    background: var(--gray-50);
    border: none;
    cursor: pointer;
    font-family: inherit;
    font-size: 14px;
    text-align: left;
    transition: background-color 0.2s;
}

.faq-category-header:hover {
    background: var(--gray-100);
}

.faq-category.expanded .faq-category-header {
    background: var(--primary);
    color: var(--white);
}

.faq-category-icon {
    font-size: 16px;
    flex-shrink: 0;
}

.faq-category-title {
    flex: 1;
    font-weight: 600;
}

.faq-category-count {
    font-size: 12px;
    padding: 2px 8px;
    background: var(--gray-200);
    border-radius: 10px;
    color: var(--gray-600);
}

.faq-category.expanded .faq-category-count {
    background: rgba(255, 255, 255, 0.2);
    color: var(--white);
}

.faq-category-arrow {
    font-size: 10px;
    transition: transform 0.2s;
    color: var(--gray-500);
}

.faq-category.expanded .faq-category-arrow {
    transform: rotate(180deg);
    color: var(--white);
}

.faq-questions-list {
    padding: 0;
}

.faq-item {
    border-top: 1px solid var(--gray-200);
}

.faq-item:first-child {
    border-top: none;
}

.faq-question {
    width: 100%;
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 12px;
    padding: 12px 14px;
    background: var(--white);
    border: none;
    cursor: pointer;
    font-family: inherit;
    font-size: 13px;
    text-align: left;
    color: var(--gray-800);
    transition: background-color 0.2s;
}

.faq-question:hover {
    background: var(--gray-50);
}

.faq-item.expanded .faq-question {
    background: var(--gray-50);
    font-weight: 500;
}

.faq-q-text {
    flex: 1;
    line-height: 1.4;
}

.faq-q-arrow {
    font-size: 18px;
    font-weight: 300;
    color: var(--primary);
    flex-shrink: 0;
    line-height: 1;
}

.faq-answer {
    padding: 0 14px 14px 14px;
    background: var(--gray-50);
}

.faq-answer p {
    font-size: 13px;
    color: var(--gray-700);
    line-height: 1.6;
    margin: 0;
}

/* =======================
   RESOURCE HUB STYLES
   ======================= */

.resource-hub {
    margin-top: 32px;
    padding: 0 24px 32px;
}

.resource-hub-header {
    background: linear-gradient(135deg, var(--primary-light, #e8f4f4) 0%, var(--primary) 100%);
    padding: 32px;
    border-radius: 12px;
    margin-bottom: 24px;
    color: var(--white);
}

.resource-hub-header h2 {
    font-size: 1.75rem;
    font-weight: 700;
    margin: 0 0 8px 0;
}

.resource-hub-header p {
    opacity: 0.9;
    font-size: 1.1rem;
    margin: 0;
}

.hub-tabs {
    display: flex;
    gap: 8px;
    margin-bottom: 24px;
    border-bottom: 2px solid var(--gray-200);
    padding-bottom: 0;
}

.hub-tabs button {
    padding: 12px 24px;
    background: none;
    border: none;
    font-weight: 500;
    font-size: 14px;
    font-family: inherit;
    color: var(--gray-600);
    cursor: pointer;
    position: relative;
    transition: color 0.2s;
}

.hub-tabs button:hover {
    color: var(--gray-900);
}

.hub-tabs button[aria-selected="true"] {
    color: var(--primary);
}

.hub-tabs button[aria-selected="true"]::after {
    content: '';
    position: absolute;
    bottom: -2px;
    left: 0;
    right: 0;
    height: 2px;
    background: var(--primary);
    border-radius: 2px 2px 0 0;
}

.hub-panel {
    animation: fadeIn 0.2s ease-out;
}

.hub-panel.hidden {
    display: none;
}

@keyframes fadeIn {
    from { opacity: 0; }
    to { opacity: 1; }
}

/* Useful Links Grid */
.links-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 16px;
}

.link-card {
    display: flex;
    flex-direction: column;
    padding: 16px 20px;
    background: var(--white);
    border: 1px solid var(--gray-200);
    border-radius: 8px;
    text-decoration: none;
    color: inherit;
    transition: transform 0.2s, box-shadow 0.2s, border-color 0.2s;
}

.link-card:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.08);
    border-color: var(--primary);
}

.link-card.hidden-overflow {
    display: none;
}

.link-category {
    font-size: 11px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    color: var(--primary);
    margin-bottom: 8px;
}

.link-title {
    font-weight: 600;
    font-size: 15px;
    margin: 0 0 4px 0;
    color: var(--gray-900);
}

.link-desc {
    font-size: 13px;
    color: var(--gray-600);
    margin: 0 0 8px 0;
    flex: 1;
}

.link-arrow {
    align-self: flex-end;
    color: var(--primary);
    font-size: 18px;
    font-weight: 500;
}

.show-more-btn {
    display: block;
    margin: 24px auto 0;
    padding: 12px 24px;
    background: var(--gray-100);
    border: 1px solid var(--gray-300);
    border-radius: var(--radius);
    font-size: 14px;
    font-weight: 500;
    font-family: inherit;
    color: var(--gray-700);
    cursor: pointer;
    transition: background 0.2s, border-color 0.2s;
}

.show-more-btn:hover {
    background: var(--gray-200);
    border-color: var(--gray-400);
}

.show-more-btn.hidden {
    display: none;
}

/* Learn Panel */
.learn-intro {
    color: var(--gray-600);
    margin: 0 0 24px 0;
    font-size: 15px;
}

.learn-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
    gap: 16px;
    margin-bottom: 32px;
}

.learn-card {
    display: flex;
    gap: 16px;
    padding: 20px;
    background: var(--white);
    border: 1px solid var(--gray-200);
    border-radius: 8px;
    cursor: pointer;
    transition: border-color 0.2s, box-shadow 0.2s;
}

.learn-card:hover {
    border-color: var(--primary);
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.06);
}

.learn-icon {
    font-size: 2rem;
    flex-shrink: 0;
    line-height: 1;
}

.learn-content {
    flex: 1;
}

.learn-time {
    font-size: 11px;
    color: var(--gray-500);
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.learn-card h4 {
    margin: 4px 0 6px 0;
    font-weight: 600;
    font-size: 15px;
    color: var(--gray-900);
}

.learn-card p {
    font-size: 13px;
    color: var(--gray-600);
    margin: 0;
    line-height: 1.5;
}

.learn-documents {
    border-top: 1px solid var(--gray-200);
    padding-top: 24px;
}

.learn-documents h4 {
    margin: 0 0 16px 0;
    font-size: 16px;
    font-weight: 600;
    color: var(--gray-900);
}

.learn-documents .documents-list {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 12px;
}

.learn-documents .document-item {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 14px 16px;
    background: var(--gray-50);
    border: 1px solid var(--gray-200);
    border-radius: var(--radius);
    text-decoration: none;
    color: inherit;
    transition: background 0.2s, border-color 0.2s;
}

.learn-documents .document-item:hover {
    background: var(--white);
    border-color: var(--primary);
}

.learn-documents .document-icon {
    font-size: 24px;
    flex-shrink: 0;
}

.learn-documents .document-info {
    flex: 1;
}

.learn-documents .document-name {
    display: block;
    font-weight: 600;
    font-size: 14px;
    color: var(--gray-900);
}

.learn-documents .document-desc {
    display: block;
    font-size: 12px;
    color: var(--gray-600);
    margin-top: 2px;
}

.learn-documents .download-icon {
    font-size: 18px;
    color: var(--primary);
    font-weight: 600;
}

/* =======================
   BREADCRUMB STYLES
   ======================= */

.breadcrumbs {
    padding: 12px 0;
    margin-bottom: 16px;
    font-size: 14px;
}

.breadcrumbs ol {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    list-style: none;
    margin: 0;
    padding: 0;
}

.breadcrumbs li {
    display: flex;
    align-items: center;
}

.breadcrumbs li:not(:last-child)::after {
    content: '›';
    margin-left: 8px;
    color: var(--gray-400);
}

.breadcrumbs a {
    color: var(--gray-600);
    text-decoration: none;
}

.breadcrumbs a:hover {
    color: var(--primary);
    text-decoration: underline;
}

.breadcrumbs [aria-current="page"] {
    color: var(--gray-900);
    font-weight: 500;
}

/* Responsive */
@media (max-width: 768px) {
    .dashboard-grid {
        grid-template-columns: 1fr;
    }

    .card {
        grid-column: span 1 !important;
    }

    .quick-stats {
        gap: 24px;
    }

    .stat-value {
        font-size: 28px;
    }

    header {
        flex-direction: column;
        gap: 12px;
        text-align: center;
    }

    .login-container {
        margin: 16px;
        padding: 32px 24px;
    }

    .site-footer {
        flex-direction: column;
        gap: 8px;
        text-align: center;
        font-size: 11.5px;
    }

    .footer-left {
        flex-direction: column;
        gap: 4px;
    }

    /* Resource Hub Mobile */
    .resource-hub {
        padding: 0 16px 24px;
    }

    .resource-hub-header {
        padding: 24px 20px;
    }

    .resource-hub-header h2 {
        font-size: 1.5rem;
    }

    .resource-hub-header p {
        font-size: 1rem;
    }

    .hub-tabs {
        gap: 4px;
        overflow-x: auto;
        -webkit-overflow-scrolling: touch;
    }

    .hub-tabs button {
        padding: 10px 16px;
        font-size: 13px;
        white-space: nowrap;
    }

    .links-grid {
        grid-template-columns: 1fr;
    }

    .learn-grid {
        grid-template-columns: 1fr;
    }

    .learn-card {
        padding: 16px;
    }

    .learn-documents .documents-list {
        grid-template-columns: 1fr;
    }

    /* Breadcrumbs Mobile */
    .breadcrumbs ol {
        gap: 4px;
    }

    .breadcrumbs li:not(:last-child)::after {
        margin-left: 4px;
    }

    .totp-setup-content {
        max-width: 100%;
        margin: 16px;
        max-height: calc(100vh - 32px);
    }

    .totp-setup-body {
        padding: 16px;
    }

    .totp-step {
        flex-direction: column;
        gap: 12px;
    }

    .step-number {
        width: 28px;
        height: 28px;
        font-size: 14px;
    }

    .app-links {
        flex-direction: column;
        gap: 8px;
    }

    .app-link {
        text-align: center;
    }

    .setup-method-tabs {
        flex-direction: column;
    }

    .method-tab:first-child {
        border-right: none;
        border-bottom: 1px solid var(--gray-300);
    }

    .totp-qr-image {
        width: 180px;
        height: 180px;
    }

    .secret-copy-container {
        flex-direction: column;
    }

    .totp-secret {
        font-size: 13px;
        letter-spacing: 1px;
    }

    .manual-entry-instructions {
        padding: 12px;
    }

    .manual-entry-instructions ol {
        font-size: 12px;
    }
}

/* Inactivity Warning */
.inactivity-warning {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.5);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 9999;
    animation: fadeIn 0.3s ease;
}

.inactivity-warning.hidden {
    display: none;
}

.inactivity-warning-content {
    background: var(--white);
    padding: 32px 40px;
    border-radius: var(--radius);
    box-shadow: var(--shadow-lg);
    text-align: center;
    max-width: 400px;
    width: 90%;
}

.inactivity-warning-content p {
    margin-bottom: 16px;
    color: var(--gray-700);
}

.inactivity-warning-content p:first-child {
    color: var(--warning);
    font-size: 1.125rem;
}

.inactivity-warning-content #inactivity-countdown {
    font-weight: 600;
    color: var(--error);
    font-variant-numeric: tabular-nums;
}

.inactivity-warning-content .btn-primary {
    margin-top: 8px;
}

@keyframes fadeIn {
    from { opacity: 0; }
    to { opacity: 1; }
}

/* Info message style for inactivity logout */
.message.info {
    background: #dbeafe;
    color: #1e40af;
    border: 1px solid #93c5fd;
}

/* Referral Banner */
.referral-banner {
    background: linear-gradient(135deg, #036666 0%, #047a7a 50%, #036666 100%);
    background-size: 200% 200%;
    animation: gradientShift 8s ease infinite;
    border-radius: 12px;
    padding: 20px 28px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 24px;
    position: relative;
    overflow: hidden;
    box-shadow: 0 4px 20px rgba(3, 102, 102, 0.3);
    margin: 24px 24px 0 24px;
    max-width: 1152px;
    margin-left: auto;
    margin-right: auto;
}

@keyframes gradientShift {
    0%, 100% { background-position: 0% 50%; }
    50% { background-position: 100% 50%; }
}

.referral-banner::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background:
        radial-gradient(circle at 10% 20%, rgba(128, 239, 128, 0.15) 0%, transparent 50%),
        radial-gradient(circle at 90% 80%, rgba(128, 239, 128, 0.1) 0%, transparent 40%);
    pointer-events: none;
}

.referral-content {
    display: flex;
    align-items: center;
    gap: 20px;
    flex: 1;
    position: relative;
    z-index: 1;
}

.referral-icon {
    width: 56px;
    height: 56px;
    background: rgba(128, 239, 128, 0.2);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    animation: referralPulse 2s ease-in-out infinite;
}

@keyframes referralPulse {
    0%, 100% { transform: scale(1); box-shadow: 0 0 0 0 rgba(128, 239, 128, 0.4); }
    50% { transform: scale(1.05); box-shadow: 0 0 0 10px rgba(128, 239, 128, 0); }
}

.referral-icon svg {
    width: 28px;
    height: 28px;
    fill: #80EF80;
}

.referral-text {
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.referral-headline {
    display: flex;
    align-items: center;
    gap: 12px;
    flex-wrap: wrap;
}

.referral-title {
    color: #ffffff;
    font-size: 18px;
    font-weight: 700;
    letter-spacing: -0.3px;
}

.referral-badge {
    background: #80EF80;
    color: #036666;
    font-size: 13px;
    font-weight: 700;
    padding: 4px 12px;
    border-radius: 20px;
    display: inline-flex;
    align-items: center;
    gap: 4px;
    animation: badgeGlow 2s ease-in-out infinite alternate;
}

@keyframes badgeGlow {
    0% { box-shadow: 0 0 5px rgba(128, 239, 128, 0.5); }
    100% { box-shadow: 0 0 15px rgba(128, 239, 128, 0.8), 0 0 30px rgba(128, 239, 128, 0.3); }
}

.referral-description {
    color: rgba(255, 255, 255, 0.9);
    font-size: 14px;
    font-weight: 400;
    line-height: 1.5;
    max-width: 500px;
}

.referral-description strong {
    color: #80EF80;
    font-weight: 600;
}

.referral-cta {
    display: flex;
    flex-direction: column;
    align-items: flex-end;
    gap: 8px;
    position: relative;
    z-index: 1;
}

.referral-btn {
    background: #ffffff;
    color: #036666;
    font-family: 'Montserrat', sans-serif;
    font-size: 14px;
    font-weight: 600;
    padding: 12px 24px;
    border: none;
    border-radius: 8px;
    cursor: pointer;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    gap: 8px;
    white-space: nowrap;
}

.referral-btn:hover {
    background: #80EF80;
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(0, 0, 0, 0.2);
}

.referral-btn svg {
    width: 16px;
    height: 16px;
    fill: currentColor;
    transition: transform 0.3s ease;
}

.referral-btn:hover svg {
    transform: translateX(4px);
}

.referral-fine-print {
    color: rgba(255, 255, 255, 0.6);
    font-size: 11px;
    font-weight: 400;
}

.referral-close {
    position: absolute;
    top: 12px;
    right: 12px;
    background: rgba(255, 255, 255, 0.1);
    border: none;
    width: 24px;
    height: 24px;
    border-radius: 50%;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.2s ease;
    z-index: 2;
}

.referral-close:hover {
    background: rgba(255, 255, 255, 0.2);
}

.referral-close svg {
    width: 12px;
    height: 12px;
    fill: rgba(255, 255, 255, 0.7);
}

.floating-coins {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    pointer-events: none;
    overflow: hidden;
}

.coin {
    position: absolute;
    width: 20px;
    height: 20px;
    opacity: 0.15;
    animation: coinFloat 6s ease-in-out infinite;
}

.coin:nth-child(1) { left: 5%; top: 20%; animation-delay: 0s; }
.coin:nth-child(2) { left: 15%; top: 60%; animation-delay: 1s; }
.coin:nth-child(3) { left: 75%; top: 30%; animation-delay: 2s; }
.coin:nth-child(4) { left: 85%; top: 70%; animation-delay: 3s; }
.coin:nth-child(5) { left: 45%; top: 15%; animation-delay: 4s; }

@keyframes coinFloat {
    0%, 100% { transform: translateY(0) rotate(0deg); }
    50% { transform: translateY(-10px) rotate(180deg); }
}

@media (max-width: 768px) {
    .referral-banner {
        flex-direction: column;
        text-align: center;
        padding: 24px 20px;
        margin: 16px;
    }

    .referral-content {
        flex-direction: column;
    }

    .referral-headline {
        justify-content: center;
    }

    .referral-description {
        text-align: center;
    }

    .referral-cta {
        align-items: center;
        width: 100%;
    }

    .referral-btn {
        width: 100%;
        justify-content: center;
    }
}
