@import url('https://fonts.googleapis.com/css2?family=Outfit:wght@300;400;600;700;800;900&display=swap');

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: 'Outfit', sans-serif;
}

body {
    background-color: #0A090E;
    color: #F4F4F5;
    min-height: 100vh;
    display: flex;
}

/* Scrollbar Customization */
::-webkit-scrollbar {
    width: 8px;
}
::-webkit-scrollbar-track {
    background: #0A090E;
}
::-webkit-scrollbar-thumb {
    background: #251F35;
    border-radius: 4px;
}
::-webkit-scrollbar-thumb:hover {
    background: #A855F7;
}

/* Sidebar Navigation */
.sidebar {
    width: 260px;
    background-color: #110E1A;
    border-right: 1px solid #251F35;
    padding: 24px 16px;
    display: flex;
    flex-direction: column;
    height: 100vh;
    position: fixed;
    left: 0;
    top: 0;
}

.sidebar-logo {
    font-size: 28px;
    font-weight: 900;
    color: #FFFFFF;
    margin-bottom: 32px;
    padding-left: 12px;
}

.sidebar-logo span {
    color: #A855F7;
}

.sidebar-menu {
    list-style: none;
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.sidebar-item a {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px 16px;
    color: #A0A0AB;
    text-decoration: none;
    font-weight: 600;
    border-radius: 10px;
    transition: all 0.2s ease-in-out;
}

.sidebar-item a:hover {
    color: #FFFFFF;
    background-color: #A855F715;
}

.sidebar-item.active a {
    color: #FFFFFF;
    background-color: #A855F7;
    box-shadow: 0 4px 12px rgba(168, 85, 247, 0.35);
}

.sidebar-logout {
    margin-top: auto;
}

.sidebar-logout a {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px 16px;
    color: #EF4444;
    text-decoration: none;
    font-weight: 600;
    border-radius: 10px;
    transition: all 0.2s ease-in-out;
}

.sidebar-logout a:hover {
    background-color: #EF444415;
}

/* Main Layout Content */
.main-content {
    margin-left: 260px;
    padding: 40px;
    flex: 1;
    min-height: 100vh;
}

/* Headings */
.page-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 32px;
}

.page-title {
    font-size: 28px;
    font-weight: 800;
    letter-spacing: -0.5px;
}

.page-subtitle {
    font-size: 14px;
    color: #A0A0AB;
    margin-top: 4px;
}

/* Buttons */
.btn {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 12px 20px;
    border-radius: 10px;
    font-weight: 700;
    text-decoration: none;
    cursor: pointer;
    transition: all 0.2s ease;
    border: none;
    font-size: 14px;
}

.btn-primary {
    background-color: #A855F7;
    color: #FFFFFF;
}

.btn-primary:hover {
    background-color: #9333EA;
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(168, 85, 247, 0.25);
}

.btn-secondary {
    background-color: #1E1B29;
    color: #FFFFFF;
    border: 1px solid #2D283E;
}

.btn-secondary:hover {
    background-color: #2D283E;
}

.btn-danger {
    background-color: #EF444415;
    color: #EF4444;
    border: 1px solid #EF444433;
}

.btn-danger:hover {
    background-color: #EF4444;
    color: #FFFFFF;
}

/* Stats Cards Grid */
.stats-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
    gap: 20px;
    margin-bottom: 32px;
}

.stat-card {
    background-color: #16121E;
    border: 1px solid #251F35;
    border-radius: 16px;
    padding: 24px;
    position: relative;
    overflow: hidden;
}

.stat-card::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 4px;
    height: 100%;
    background-color: #A855F7;
}

.stat-title {
    font-size: 12px;
    font-weight: 800;
    color: #A0A0AB;
    text-transform: uppercase;
    letter-spacing: 1px;
}

.stat-value {
    font-size: 32px;
    font-weight: 900;
    color: #FFFFFF;
    margin-top: 8px;
}

.stat-desc {
    font-size: 12px;
    color: #71717A;
    margin-top: 4px;
}

/* Cards & Sections */
.admin-card {
    background-color: #16121E;
    border: 1px solid #251F35;
    border-radius: 16px;
    padding: 24px;
    margin-bottom: 24px;
}

.form-title {
    font-size: 18px;
    font-weight: 800;
    margin-bottom: 20px;
}

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

.form-label {
    display: block;
    font-size: 13px;
    font-weight: 700;
    color: #A0A0AB;
    margin-bottom: 8px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.form-control {
    width: 100%;
    background-color: #0A090E;
    border: 1px solid #251F35;
    border-radius: 8px;
    padding: 12px 16px;
    color: #FFFFFF;
    font-size: 14px;
    transition: border-color 0.2s ease;
}

.form-control:focus {
    outline: none;
    border-color: #A855F7;
}

/* Tables */
.table-wrapper {
    overflow-x: auto;
    background-color: #16121E;
    border: 1px solid #251F35;
    border-radius: 16px;
}

.admin-table {
    width: 100%;
    border-collapse: collapse;
    text-align: left;
    font-size: 14px;
}

.admin-table th {
    background-color: #1E1A29;
    padding: 16px 20px;
    font-weight: 800;
    color: #A0A0AB;
    border-bottom: 1px solid #251F35;
    text-transform: uppercase;
    font-size: 11px;
    letter-spacing: 0.5px;
}

.admin-table td {
    padding: 16px 20px;
    border-bottom: 1px solid #251F35;
    color: #E4E4E7;
    vertical-align: middle;
}

.admin-table tr:last-child td {
    border-bottom: none;
}

.admin-table tr:hover td {
    background-color: #211B2C40;
}

/* Login Page Styling */
.login-container {
    width: 100%;
    display: flex;
    justify-content: center;
    align-items: center;
    min-height: 100vh;
    background-color: #0A090E;
    padding: 20px;
}

.login-card {
    width: 100%;
    max-width: 420px;
    background-color: #16121E;
    border: 1px solid #251F35;
    border-radius: 20px;
    padding: 40px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.5);
}

.login-header {
    text-align: center;
    margin-bottom: 32px;
}

.login-logo {
    font-size: 36px;
    font-weight: 900;
    color: #FFFFFF;
}

.login-logo span {
    color: #A855F7;
}

.login-subtitle {
    font-size: 14px;
    color: #A0A0AB;
    margin-top: 8px;
}

.alert-danger {
    background-color: #EF444415;
    border: 1px solid #EF444433;
    color: #EF4444;
    padding: 12px 16px;
    border-radius: 10px;
    font-size: 13px;
    margin-bottom: 20px;
}

.alert-success {
    background-color: #10B98115;
    border: 1px solid #10B98133;
    color: #10B981;
    padding: 12px 16px;
    border-radius: 10px;
    font-size: 13px;
    margin-bottom: 20px;
}

/* Treinos / Exercicios Sheet CSS styling */
.sheet-row {
    display: grid;
    grid-template-columns: 1fr 2fr;
    gap: 24px;
    align-items: start;
}

.exercise-list-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 14px 18px;
    background-color: #0A090E;
    border: 1px solid #251F35;
    border-radius: 10px;
    margin-bottom: 10px;
}

.exercise-details {
    font-size: 13px;
    color: #A0A0AB;
    margin-top: 4px;
}
.exercise-name {
    font-weight: 700;
    color: #FFFFFF;
}
.badge-muscle {
    background-color: #A855F722;
    color: #A855F7;
    font-size: 10px;
    font-weight: 800;
    padding: 2px 6px;
    border-radius: 4px;
    text-transform: uppercase;
}

/* Modal Styling */
.modal {
    display: none;
    position: fixed; 
    z-index: 1000; 
    left: 0;
    top: 0;
    width: 100%; 
    height: 100%; 
    overflow: auto; 
    background-color: rgba(10, 9, 14, 0.8); 
    backdrop-filter: blur(8px);
    align-items: center;
    justify-content: center;
}

.modal.active {
    display: flex;
    animation: fadeIn 0.25s ease-out;
}

.modal-content {
    background-color: #16121E;
    border: 1px solid #251F35;
    border-radius: 20px;
    width: 90%;
    max-width: 500px;
    padding: 32px;
    position: relative;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.6);
    animation: slideUp 0.3s cubic-bezier(0.16, 1, 0.3, 1);
}

.close-modal {
    position: absolute;
    top: 20px;
    right: 20px;
    font-size: 24px;
    color: #A0A0AB;
    cursor: pointer;
    background: none;
    border: none;
    transition: color 0.2s ease;
}

.close-modal:hover {
    color: #FFFFFF;
}

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

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

@keyframes pulse {
    0% {
        transform: scale(0.95);
        box-shadow: 0 0 0 0 rgba(16, 185, 129, 0.7);
    }
    70% {
        transform: scale(1);
        box-shadow: 0 0 0 6px rgba(16, 185, 129, 0);
    }
    100% {
        transform: scale(0.95);
        box-shadow: 0 0 0 0 rgba(16, 185, 129, 0);
    }
}
