/**
 * Athena Gym Management System
 * Centralized CSS Variables
 *
 * This file contains all the color variables and common styles
 * used throughout the application to maintain consistency.
 */

:root {
    /* Primary Colors - Based on Sneat Theme */
    --athena-primary: #435971;
    --athena-primary-light: #566a7f;
    --athena-primary-lighter: #6f7f93;
    --athena-primary-dark: #2c3e50;
    --athena-primary-darker: #1a252f;

    /* Background Colors */
    --athena-bg-primary: linear-gradient(135deg, #435971 0%, #566a7f 100%);
    --athena-bg-section: linear-gradient(135deg, #f4f5f7 0%, #e7eaf0 100%);
    --athena-bg-light: #f8f9fa;
    --athena-bg-white: #ffffff;
    --athena-bg-card: #2c3e50;

    /* Text Colors */
    --athena-text-primary: #435971;
    --athena-text-secondary: #566a7f;
    --athena-text-muted: #6c757d;
    --athena-text-light: #858e96;
    --athena-text-dark: #495057;

    /* Status Colors */
    --athena-success: #28a745;
    --athena-success-light: #d4edda;
    --athena-success-dark: #1a9a49;
    --athena-warning: #ffc107;
    --athena-warning-light: #fff3cd;
    --athena-danger: #dc3545;
    --athena-danger-light: #f8d7da;
    --athena-info: #17a2b8;
    --athena-info-light: #d1ecf1;

    /* Border Colors */
    --athena-border: #dee2e6;
    --athena-border-light: #e7eaf0;
    --athena-border-primary: #435971;

    /* Shadow */
    --athena-shadow-sm: 0 1px 3px rgba(0, 0, 0, 0.1);
    --athena-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
    --athena-shadow-lg: 0 4px 12px rgba(0, 0, 0, 0.15);

    /* Overlays */
    --athena-overlay: rgba(67, 89, 113, 0.5); /* Primary color with transparency for modals/sheets */

    /* Border Radius */
    --athena-radius-sm: 4px;
    --athena-radius: 8px;
    --athena-radius-lg: 12px;

    /* Spacing */
    --athena-spacing-xs: 0.25rem;
    --athena-spacing-sm: 0.5rem;
    --athena-spacing: 1rem;
    --athena-spacing-lg: 1.5rem;
    --athena-spacing-xl: 2rem;
}

/* Common Styles */

/* Profile Header */
.athena-profile-header {
    background: var(--athena-bg-primary);
    border-radius: var(--athena-radius-lg);
    color: white !important;
    padding: var(--athena-spacing-xl);
    margin-bottom: var(--athena-spacing-xl);
    box-shadow: var(--athena-shadow-lg);
}

.athena-profile-header h1,
.athena-profile-header h2,
.athena-profile-header h3,
.athena-profile-header h4,
.athena-profile-header h5,
.athena-profile-header h6,
.athena-profile-header p,
.athena-profile-header span,
.athena-profile-header i {
    color: white !important;
}

/* Section Header */
.athena-section-header,
.section-header {
    background: var(--athena-bg-section);
    border-radius: var(--athena-radius);
    padding: var(--athena-spacing);
    margin: var(--athena-spacing-lg) 0 var(--athena-spacing) 0;
    border-left: 4px solid var(--athena-border-primary);
}

.athena-section-header h5,
.athena-section-header h6,
.section-header h5,
.section-header h6 {
    color: var(--athena-text-secondary) !important;
    margin-bottom: 0;
    font-weight: 600;
}

.athena-section-header i,
.section-header i {
    color: var(--athena-primary) !important;
}

/* Cards */
.athena-card {
    background: var(--athena-bg-card);
    border-radius: var(--athena-radius);
    box-shadow: var(--athena-shadow);
    border: 1px solid var(--athena-border);
    color: #e5e7eb;
}

.athena-card-header {
    background: var(--athena-bg-light);
    border-bottom: 1px solid var(--athena-border);
    padding: var(--athena-spacing);
    font-weight: 600;
}

/* Form Sections */
.athena-form-section {
    background: var(--athena-bg-light);
    border-radius: var(--athena-radius);
    padding: var(--athena-spacing-lg);
    margin-bottom: var(--athena-spacing-lg);
}

.athena-form-section h5 {
    color: var(--athena-text-dark);
    margin-bottom: var(--athena-spacing);
    font-weight: 600;
}

/* Help Text */
.athena-help-text,
.form-text.text-muted,
small.text-muted {
    font-size: 0.85rem;
    color: var(--athena-text-muted);
    margin-top: var(--athena-spacing-xs);
}

/* Status Badges */
.athena-badge-active,
.badge-active {
    background-color: var(--athena-success) !important;
}

.athena-badge-inactive,
.badge-inactive {
    background-color: var(--athena-text-muted) !important;
}

.athena-badge-expired,
.badge-expired {
    background-color: var(--athena-danger) !important;
}

.athena-badge-future,
.badge-future {
    background-color: var(--athena-info) !important;
}

.athena-badge-pending,
.badge-pending {
    background-color: var(--athena-warning) !important;
    color: #000 !important;
}

/* Table Styles */
.athena-table {
    background: var(--athena-bg-white);
}

.athena-table thead {
    background: var(--athena-bg-light);
}

.athena-table-hover tbody tr:hover {
    background-color: var(--athena-bg-light);
    cursor: pointer;
}

/* Filters */
.athena-filter-section {
    background: var(--athena-bg-light);
    border-radius: var(--athena-radius);
    padding: var(--athena-spacing);
    margin-bottom: var(--athena-spacing);
}

/* Stats Cards */
.athena-stats-card {
    border-left: 4px solid;
    transition: transform 0.2s, box-shadow 0.2s;
}

.athena-stats-card:hover {
    transform: translateY(-2px);
    box-shadow: var(--athena-shadow-lg);
}

/* Alert Styles */
.athena-alert-info {
    background: var(--athena-info-light);
    border: 1px solid var(--athena-info);
    border-radius: var(--athena-radius);
    padding: var(--athena-spacing);
}

.athena-alert-warning {
    background: var(--athena-warning-light);
    border: 1px solid var(--athena-warning);
    border-radius: var(--athena-radius);
    padding: var(--athena-spacing);
}

.athena-alert-danger {
    background: var(--athena-danger-light);
    border: 1px solid var(--athena-danger);
    border-radius: var(--athena-radius);
    padding: var(--athena-spacing);
}

.athena-alert-success {
    background: var(--athena-success-light);
    border: 1px solid var(--athena-success);
    border-radius: var(--athena-radius);
    padding: var(--athena-spacing);
}

/* Calculation Boxes */
.athena-calculation-box {
    background: var(--athena-bg-light);
    border-radius: var(--athena-radius);
    padding: var(--athena-spacing);
}

.athena-total-display {
    font-size: 1.5rem;
    font-weight: bold;
    color: var(--athena-primary);
}

/* Preview Boxes */
.athena-salary-preview,
.athena-preview-box {
    background: var(--athena-info-light);
    border: 1px solid var(--athena-info);
    border-radius: var(--athena-radius-sm);
    padding: var(--athena-spacing);
    margin-top: var(--athena-spacing);
}

/* Buttons */
.btn-athena-primary {
    background-color: var(--athena-primary);
    border-color: var(--athena-primary);
    color: white;
}

.btn-athena-primary:hover {
    background-color: var(--athena-primary-dark);
    border-color: var(--athena-primary-dark);
    color: white;
}

/* Mobile Responsive Adjustments */
@media (max-width: 767.98px) {
    .athena-profile-header {
        padding: var(--athena-spacing);
    }

    .athena-section-header {
        padding: var(--athena-spacing-sm) var(--athena-spacing);
    }

    .athena-form-section {
        padding: var(--athena-spacing);
    }
}

/* Dark Mode Support (if needed in future) */
@media (prefers-color-scheme: dark) {
    :root {
        --athena-bg-white: #2a2e33;
        --athena-bg-card: #2a2e33;
        --athena-bg-light: #1f2228;
        --athena-border: #404040;
        --athena-text-dark: #e5e7eb;
        --athena-text-muted: #9ca3af;
    }
}

/* ========================================
   BUTTON PLACEMENT PATTERNS
   ======================================== */

/* Mobile Action Footer (Fixed) */
.mobile-action-footer {
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    padding: var(--athena-spacing);
    background: var(--athena-primary-darker);
    border-top: 1px solid var(--athena-border);
    box-shadow: 0 -2px 10px rgba(0, 0, 0, 0.1);
    z-index: 1000;
}

@media (min-width: 768px) {
    .mobile-action-footer {
        display: none;
    }
}

/* Desktop Form Footer */
.desktop-form-footer {
    display: none;
}

@media (min-width: 768px) {
    .desktop-form-footer {
        display: block;
        padding: var(--athena-spacing-lg);
        text-align: right;
        border-top: 1px solid var(--athena-border);
        background: var(--athena-bg-white);
    }
}

/* Page Header Mobile */
.page-header-mobile {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: var(--athena-spacing);
    border-bottom: 1px solid var(--athena-border);
    position: sticky;
    top: 0;
    background: var(--athena-primary-darker);
    z-index: 99;
    margin-bottom: var(--athena-spacing);
}

.page-header-mobile .page-title {
    font-size: 1.125rem;
    font-weight: 600;
    margin: 0;
    flex: 1;
    text-align: center;
    color: var(--athena-text-dark);
}

@media (min-width: 768px) {
    .page-header-mobile {
        display: none;
    }
}

/* Floating Action Button */
.fab-button {
    position: fixed;
    bottom: 20px;
    right: 20px;
    width: 56px;
    height: 56px;
    border-radius: 50%;
    background: var(--athena-primary);
    color: white;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 24px;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.25);
    z-index: 1000;
    transition: transform 0.2s, box-shadow 0.2s;
    border: none;
    text-decoration: none;
}

.fab-button:hover {
    transform: scale(1.05);
    box-shadow: 0 6px 16px rgba(0, 0, 0, 0.3);
    color: white;
    background: var(--athena-primary-dark);
}

.fab-button:active {
    transform: scale(0.95);
}

@media (min-width: 768px) {
    .fab-button {
        display: none !important;
    }
}

/* Button Icon Helper */
.btn-icon {
    padding: 0.5rem;
    background: transparent;
    border: none;
    color: var(--athena-text-dark);
    font-size: 1.5rem;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 40px;
    min-height: 40px;
    border-radius: 50%;
    transition: background 0.2s;
}

.btn-icon:hover {
    background: var(--athena-bg-light);
    color: var(--athena-text-dark);
}

/* Text Button (for cancel actions) */
.btn-text {
    background: transparent;
    border: none;
    padding: 0.5rem 1rem;
    font-weight: 500;
    font-size: 0.875rem;
    transition: background 0.2s;
}

.btn-text.text-danger:hover {
    background: rgba(220, 53, 69, 0.1);
    border-radius: var(--athena-radius-sm);
}

/* Add padding-bottom to prevent fixed footer from hiding content */
@media (max-width: 767.98px) {
    .layout-page {
        padding-bottom: 80px !important;
    }
}

/* Detail Page Header (for view/detail pages) */
.detail-page-header-mobile {
    display: flex;
    align-items: center;
    padding: var(--athena-spacing);
    border-bottom: 1px solid var(--athena-border);
    position: sticky;
    top: 0;
    background: var(--athena-primary-darker);
    z-index: 99;
    margin-bottom: var(--athena-spacing);
}

.detail-page-header-mobile .page-title {
    font-size: 1rem;
    font-weight: 600;
    margin: 0;
    flex: 1;
    text-align: center;
    color: var(--athena-text-dark);
    padding: 0 var(--athena-spacing-sm);
}

@media (min-width: 768px) {
    .detail-page-header-mobile {
        display: none;
    }
}
