:root {
    --bg: #0a0a0f;
    --bg-card: rgba(20, 20, 30, 0.85);
    --primary: #6366f1;
    --primary-glow: rgba(99, 102, 241, 0.3);
    --accent: #10b981;
    --danger: #ef4444;
    --warn: #f59e0b;
    --text: #ffffff;
    --text-muted: #e2e8f0;
    --border: rgba(255, 255, 255, 0.15);
    --shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.8);
}

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

body {
    font-family: 'Inter', sans-serif;
    background: var(--bg);
    color: var(--text);
    min-height: 100vh;
    overflow-x: hidden;
    font-size: 16px;
}

/* Animated Background */
.bg-animation {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: -1;
    overflow: hidden;
    background: radial-gradient(ellipse at top left, rgba(99, 102, 241, 0.15), transparent 50%),
        radial-gradient(ellipse at bottom right, rgba(16, 185, 129, 0.1), transparent 50%);
}

.floating-shape {
    position: absolute;
    border-radius: 50%;
    background: linear-gradient(135deg, var(--primary), transparent);
    opacity: 0.1;
    animation: float 20s ease-in-out infinite;
}

.shape1 {
    width: 400px;
    height: 400px;
    top: -100px;
    left: -100px;
    animation-delay: 0s;
}

.shape2 {
    width: 300px;
    height: 300px;
    top: 50%;
    right: -100px;
    background: linear-gradient(135deg, var(--accent), transparent);
    animation-delay: -7s;
    animation-duration: 25s;
}

.shape3 {
    width: 200px;
    height: 200px;
    bottom: -50px;
    left: 30%;
    background: linear-gradient(135deg, #a855f7, transparent);
    animation-delay: -14s;
    animation-duration: 18s;
}

@keyframes float {

    0%,
    100% {
        transform: translate(0, 0) rotate(0deg) scale(1);
    }

    25% {
        transform: translate(30px, -30px) rotate(90deg) scale(1.1);
    }

    50% {
        transform: translate(0, 20px) rotate(180deg) scale(1);
    }

    75% {
        transform: translate(-30px, -20px) rotate(270deg) scale(1.05);
    }
}

/* Screen Management */
.screen {
    display: none;
    min-height: 100vh;
}

.screen.active {
    display: flex;
    animation: fadeIn 0.6s ease;
}

@keyframes fadeIn {
    from {
        opacity: 0;
    }

    to {
        opacity: 1;
    }
}

@keyframes slideUp {
    from {
        opacity: 0;
        transform: translateY(40px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes pulse {

    0%,
    100% {
        transform: scale(1);
        box-shadow: 0 0 0 0 var(--primary-glow);
    }

    50% {
        transform: scale(1.02);
        box-shadow: 0 0 30px 10px var(--primary-glow);
    }
}

@keyframes glow {

    0%,
    100% {
        box-shadow: 0 0 20px var(--primary-glow);
    }

    50% {
        box-shadow: 0 0 40px var(--primary-glow), 0 0 60px var(--primary-glow);
    }
}

/* Login Screen */
#login-screen {
    justify-content: center;
    align-items: center;
    flex-direction: column;
}

.login-card {
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: 28px;
    padding: 3rem;
    text-align: center;
    backdrop-filter: blur(24px);
    box-shadow: var(--shadow), 0 0 60px rgba(99, 102, 241, 0.1);
    animation: slideUp 0.8s cubic-bezier(0.16, 1, 0.3, 1), glow 4s ease-in-out infinite;
    max-width: 420px;
    width: 90%;
    position: relative;
}

.logo-container {
    margin-bottom: 1.5rem;
    animation: pulse 3s ease-in-out infinite;
}

.login-logo {
    width: 100px;
    height: 100px;
    border-radius: 24px;
    object-fit: contain;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.3);
}

.login-card h1 {
    font-size: 1.75rem;
    font-weight: 800;
    margin-bottom: 0.25rem;
    background: linear-gradient(to right, #fff, #94a3b8);
    background-clip: text;
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    animation: fadeIn 1s ease 0.3s both;
}

.login-subtitle {
    color: var(--text-muted);
    margin-bottom: 2rem;
    font-size: 0.9rem;
    animation: fadeIn 1s ease 0.5s both;
}

.login-form {
    text-align: left;
    animation: fadeIn 1s ease 0.7s both;
}

.login-form .form-group {
    margin-bottom: 1.25rem;
}

.login-form label {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-size: 0.9rem;
    font-weight: 600;
    color: var(--text-muted);
    margin-bottom: 0.5rem;
}

.login-form label i {
    color: var(--primary);
}

.login-form input {
    width: 100%;
    padding: 1rem 1.25rem;
    background: rgba(0, 0, 0, 0.4);
    border: 1px solid var(--border);
    border-radius: 14px;
    color: var(--text);
    font-size: 0.95rem;
    transition: all 0.3s;
}

.login-form input:focus {
    outline: none;
    border-color: var(--primary);
    box-shadow: 0 0 20px var(--primary-glow);
    background: rgba(99, 102, 241, 0.05);
}

.btn-login-submit {
    width: 100%;
    padding: 1.1rem;
    background: linear-gradient(135deg, var(--primary), #4f46e5);
    color: white;
    border: none;
    border-radius: 14px;
    font-weight: 700;
    font-size: 1rem;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    transition: all 0.3s;
    margin-top: 0.5rem;
    animation: fadeIn 1s ease 0.9s both;
}

.btn-login-submit:hover {
    transform: translateY(-3px) scale(1.02);
    box-shadow: 0 10px 30px var(--primary-glow);
}

.login-footer {
    margin-top: 2rem;
    color: var(--text-muted);
    font-size: 0.75rem;
    text-transform: uppercase;
    letter-spacing: 1px;
    animation: fadeIn 1s ease 1.1s both;
}

/* Dashboard */
#main-dashboard {
    flex-direction: column;
}

.top-header {
    padding: 1rem 2rem;
    display: flex;
    align-items: center;
    justify-content: space-between;
    background: var(--bg-card);
    backdrop-filter: blur(20px);
    border-bottom: 1px solid var(--border);
    position: sticky;
    top: 0;
    z-index: 100;
}

.brand {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    font-size: 1.25rem;
    font-weight: 900;
    color: white;
}

.brand-logo {
    width: 40px;
    height: 40px;
    border-radius: 10px;
    object-fit: contain;
}

.top-nav {
    display: flex;
    gap: 0.5rem;
}

.nav-item {
    padding: 0.6rem 1.25rem;
    border-radius: 10px;
    color: var(--text-muted);
    font-weight: 600;
    font-size: 0.9rem;
    display: flex;
    align-items: center;
    gap: 0.5rem;
    transition: all 0.3s;
    cursor: pointer;
}

.nav-item:hover {
    color: white;
    background: rgba(255, 255, 255, 0.05);
}

.nav-item.active {
    color: var(--primary);
    background: rgba(99, 102, 241, 0.1);
}

.nav-badge {
    background: var(--danger);
    color: white;
    font-size: 0.65rem;
    padding: 0.15rem 0.5rem;
    border-radius: 20px;
    font-weight: 700;
}

.user-info {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    color: var(--text-muted);
    font-weight: 500;
    font-size: 0.9rem;
}

.btn-logout {
    width: 36px;
    height: 36px;
    border-radius: 10px;
    border: none;
    background: rgba(239, 68, 68, 0.1);
    color: var(--danger);
    cursor: pointer;
    transition: all 0.3s;
}

.btn-logout:hover {
    background: var(--danger);
    color: white;
    transform: rotate(180deg);
}

/* Main Content */
.main-content {
    padding: 2rem;
    overflow-y: auto;
    flex: 1;
}

.dash-section {
    display: none;
    animation: slideUp 0.5s ease;
}

.dash-section.active {
    display: block;
}

/* Stats Grid with staggered animation */
.stats-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 1.5rem;
    margin-bottom: 2rem;
}

.form-row {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
    gap: 1.5rem;
    margin-bottom: 1.5rem;
}

.stat-card {
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: 18px;
    padding: 1.5rem;
    display: flex;
    align-items: center;
    gap: 1.25rem;
    cursor: pointer;
    transition: all 0.4s cubic-bezier(0.16, 1, 0.3, 1);
    backdrop-filter: blur(10px);
}

.stat-card.animate-card:nth-child(1) {
    animation: slideUp 0.5s ease 0.1s both;
}

.stat-card.animate-card:nth-child(2) {
    animation: slideUp 0.5s ease 0.2s both;
}

.stat-card.animate-card:nth-child(3) {
    animation: slideUp 0.5s ease 0.3s both;
}

.stat-card.animate-card:nth-child(4) {
    animation: slideUp 0.5s ease 0.4s both;
}

.stat-card:hover {
    transform: translateY(-8px) scale(1.02);
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.4), 0 0 30px var(--primary-glow);
    border-color: var(--primary);
}

.stat-icon {
    width: 56px;
    height: 56px;
    border-radius: 16px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.25rem;
    transition: all 0.3s;
}

.stat-card:hover .stat-icon {
    transform: scale(1.1);
}

.stat-icon.blue {
    background: rgba(99, 102, 241, 0.15);
    color: var(--primary);
}

.stat-icon.red {
    background: rgba(239, 68, 68, 0.15);
    color: var(--danger);
}

.stat-icon.status-paid {
    background: rgba(16, 185, 129, 0.2);
    color: #10b981;
    border: 1px solid rgba(16, 185, 129, 0.3);
}

.status-unpaid {
    background: rgba(245, 158, 11, 0.2);
    color: #f59e0b;
    border: 1px solid rgba(245, 158, 11, 0.3);
}

.status-overdue {
    background: rgba(239, 68, 68, 0.2);
    color: #ef4444;
    border: 1px solid rgba(239, 68, 68, 0.3);
    font-weight: 700;
}

.status-badge {
    padding: 4px 8px;
    border-radius: 6px;
    font-size: 0.75rem;
    font-weight: 600;
    white-space: nowrap;
}

.stat-icon.purple {
    background: rgba(168, 85, 247, 0.15);
    color: #a855f7;
}

.stat-icon.green {
    background: rgba(16, 185, 129, 0.15);
    color: var(--accent);
}

.stat-value {
    font-size: 1.75rem;
    font-weight: 800;
    line-height: 1;
}

.stat-label {
    color: var(--text-muted);
    font-size: 0.75rem;
    margin-top: 0.25rem;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.stat-details {
    display: flex;
    flex-direction: column;
}

/* Chart */
.chart-card {
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: 18px;
    padding: 2rem;
    animation: slideUp 0.5s ease 0.5s both;
}

.chart-card h3 {
    margin-bottom: 1.5rem;
    font-weight: 700;
}

.chart-wrapper {
    height: 300px;
}

/* Table Section */
.section-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 1.5rem;
}

.section-header h2 {
    font-size: 1.5rem;
    font-weight: 800;
}

.header-actions {
    display: flex;
    gap: 0.75rem;
}

.btn-action {
    padding: 0.6rem 1.25rem;
    border-radius: 10px;
    border: 1px solid var(--border);
    background: rgba(255, 255, 255, 0.05);
    color: var(--text-muted);
    font-weight: 600;
    font-size: 0.85rem;
    cursor: pointer;
    display: flex;
    align-items: center;
    gap: 0.4rem;
    transition: all 0.3s;
}

.btn-action:hover {
    background: rgba(255, 255, 255, 0.1);
    color: white;
    transform: translateY(-2px);
}

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

.btn-action.primary:hover {
    box-shadow: 0 8px 20px var(--primary-glow);
}

.table-wrapper {
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: 18px;
    overflow: hidden;
    animation: slideUp 0.5s ease 0.2s both;
}

table {
    width: 100%;
    border-collapse: collapse;
}

th {
    padding: 1rem 0.75rem;
    text-align: left;
    font-size: 0.75rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.75px;
    color: var(--text);
    background: linear-gradient(180deg, rgba(20, 20, 35, 0.98) 0%, rgba(15, 15, 28, 0.95) 100%);
    border-bottom: 1px solid var(--border);
    position: sticky;
    top: 0;
    z-index: 10;
    backdrop-filter: blur(10px);
}

/* Fix admin-only columns in tables */
th.admin-only,
td.admin-only {
    display: table-cell !important;
}

td {
    padding: 1rem 0.75rem;
    font-size: 0.85rem;
    border-bottom: 1px solid var(--border);
    transition: all 0.3s;
}

tr:hover td {
    background: rgba(99, 102, 241, 0.05);
}

.filter-box {
    margin-top: 0.5rem;
}

.filter-box select {
    width: 100%;
    padding: 0.5rem 0.75rem;
    background: rgba(15, 15, 25, 0.9);
    border: 1px solid var(--border);
    border-radius: 8px;
    color: var(--text-muted);
    font-size: 0.75rem;
    cursor: pointer;
    outline: none;
    transition: all 0.3s;
    appearance: none;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 24 24' fill='none' stroke='%2394a3b8' stroke-width='2'%3E%3Cpath d='M6 9l6 6 6-6'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 0.5rem center;
    padding-right: 1.5rem;
}

.filter-box select option {
    background: #1a1a2e;
    color: var(--text);
    padding: 0.5rem;
}

.filter-box select:focus {
    border-color: var(--primary);
    box-shadow: 0 0 15px var(--primary-glow);
    color: var(--text);
}

.filter-box select:hover {
    border-color: rgba(99, 102, 241, 0.5);
    background: rgba(20, 20, 35, 0.95);
}


/* Status badges in table */
.status-badge {
    padding: 0.4rem 0.8rem;
    border-radius: 20px;
    font-size: 0.75rem;
    font-weight: 700;
    white-space: nowrap;
    display: inline-block;
}

.status-paid {
    background: rgba(16, 185, 129, 0.15);
    color: var(--accent);
    border: 1px solid rgba(16, 185, 129, 0.3);
}

.status-unpaid {
    background: rgba(245, 158, 11, 0.15);
    color: var(--warn);
    border: 1px solid rgba(245, 158, 11, 0.3);
}

.status-overdue {
    background: rgba(239, 68, 68, 0.15);
    color: var(--danger);
    border: 1px solid rgba(239, 68, 68, 0.3);
    box-shadow: 0 0 10px rgba(239, 68, 68, 0.1);
}

.status-advance {
    background: rgba(99, 102, 241, 0.15);
    color: var(--primary);
    border: 1px solid rgba(99, 102, 241, 0.3);
}

/* Visualization Period Tabs */
.stats-controls {
    margin-bottom: 2rem;
    display: flex;
    justify-content: center;
}

.period-tabs {
    background: var(--bg-card);
    padding: 0.5rem;
    border-radius: 14px;
    border: 1px solid var(--border);
    display: flex;
    gap: 0.5rem;
}

.period-btn {
    padding: 0.6rem 1.5rem;
    border: none;
    border-radius: 10px;
    background: transparent;
    color: var(--text-muted);
    font-weight: 700;
    cursor: pointer;
    transition: all 0.3s;
}

.period-btn.active {
    background: var(--primary);
    color: white;
    box-shadow: 0 4px 15px var(--primary-glow);
}

.period-btn:hover:not(.active) {
    background: rgba(255, 255, 255, 0.05);
    color: white;
}

.charts-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 1.5rem;
}

.payments-summary {
    display: flex;
    gap: 1.5rem;
    margin-bottom: 1rem;
}

.insight-card {
    grid-column: span 2;
    background: linear-gradient(135deg, rgba(99, 102, 241, 0.1), rgba(16, 185, 129, 0.05));
    border: 1px solid var(--primary);
    padding: 1.5rem;
    border-radius: 18px;
    margin-bottom: 2rem;
}

.insight-item {
    display: flex;
    align-items: center;
    gap: 1rem;
    margin-bottom: 0.75rem;
}

.insight-item i {
    color: var(--primary);
}

.action-btn {
    width: 26px;
    height: 26px;
    border-radius: 6px;
    border: none;
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s;
    margin-right: 0.15rem;
    font-size: 0.7rem;
}

.actions-cell {
    display: flex;
    align-items: center;
    gap: 0.15rem;
}

.action-btn.edit {
    background: rgba(99, 102, 241, 0.15);
    color: var(--primary);
}

.action-btn.photo {
    background: rgba(16, 185, 129, 0.15);
    color: var(--accent);
}

.action-btn.delete {
    background: rgba(239, 68, 68, 0.15);
    color: var(--danger);
}

.action-btn:hover {
    transform: scale(1.15) rotate(5deg);
}

/* Modal */
.modal {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.85);
    backdrop-filter: blur(12px);
    z-index: 1000;
    justify-content: center;
    align-items: center;
    padding: 1rem;
}

.modal.active {
    display: flex;
    animation: fadeIn 0.3s ease;
}

.modal-dialog {
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: 24px;
    width: 100%;
    max-width: 950px;
    /* Increased width to accommodate side-by-side fields */
    max-height: 90vh;
    overflow: hidden;
    animation: slideUp 0.4s cubic-bezier(0.16, 1, 0.3, 1);
    box-shadow: 0 0 60px var(--primary-glow);
}

.form-group label {
    display: block;
    font-size: 0.95rem;
    /* Slightly larger */
    font-weight: 700;
    /* Bolder */
    color: #ffffff;
    /* Brighter white */
    margin-bottom: 0.6rem;
}

/* Undo Toast */
.undo-toast {
    position: fixed;
    bottom: 2rem;
    left: 50%;
    transform: translateX(-50%) translateY(150px);
    background: #1e293b;
    color: white;
    padding: 1.25rem 2.5rem;
    border-radius: 14px;
    box-shadow: 0 15px 40px rgba(0, 0, 0, 0.6);
    display: flex;
    align-items: center;
    gap: 2rem;
    z-index: 9999;
    transition: transform 0.5s cubic-bezier(0.16, 1, 0.3, 1);
    border: 1px solid rgba(255, 255, 255, 0.2);
}

.undo-toast.active {
    transform: translateX(-50%) translateY(0);
}

.btn-undo {
    background: #ffffff;
    color: #1e293b;
    border: none;
    padding: 0.5rem 1.25rem;
    border-radius: 8px;
    font-weight: 800;
    font-size: 0.85rem;
    cursor: pointer;
    transition: all 0.2s;
}

.btn-undo:hover {
    background: var(--primary);
    color: white;
    transform: scale(1.05);
}

.modal-header {
    padding: 1.25rem 1.5rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
    border-bottom: 1px solid var(--border);
    background: rgba(0, 0, 0, 0.2);
}

.modal-header h3 {
    font-size: 1.1rem;
    font-weight: 700;
}

.modal-close {
    width: 36px;
    height: 36px;
    border-radius: 10px;
    border: none;
    background: rgba(255, 255, 255, 0.05);
    color: var(--text-muted);
    cursor: pointer;
    transition: all 0.3s;
}

.modal-close:hover {
    background: var(--danger);
    color: white;
    transform: rotate(90deg);
}

.form-body {
    padding: 1.5rem;
    overflow-y: auto;
    max-height: 60vh;
}

.form-row {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 1rem;
    margin-bottom: 1rem;
}

.form-group label {
    display: block;
    font-size: 0.75rem;
    font-weight: 600;
    color: var(--text-muted);
    margin-bottom: 0.4rem;
}

.form-group input {
    width: 100%;
    padding: 0.75rem 0.9rem;
    background: rgba(0, 0, 0, 0.3);
    border: 1px solid var(--border);
    border-radius: 10px;
    color: var(--text);
    font-size: 0.85rem;
    transition: all 0.3s;
}

.form-group input:focus {
    outline: none;
    border-color: var(--primary);
    box-shadow: 0 0 15px var(--primary-glow);
}

/* Form Select Styling */
.form-group select {
    width: 100%;
    padding: 0.75rem 0.9rem;
    background: rgba(0, 0, 0, 0.3);
    border: 1px solid var(--border);
    border-radius: 10px;
    color: var(--text);
    font-size: 0.85rem;
    transition: all 0.3s;
    cursor: pointer;
    appearance: none;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 24 24' fill='none' stroke='%2394a3b8' stroke-width='2'%3E%3Cpath d='M6 9l6 6 6-6'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 0.75rem center;
    padding-right: 2rem;
}

.form-group select:focus {
    outline: none;
    border-color: var(--primary);
    box-shadow: 0 0 15px var(--primary-glow);
}

.form-group select:hover {
    border-color: rgba(99, 102, 241, 0.5);
}

.form-group select option {
    background: #1a1a2e;
    color: var(--text);
    padding: 0.5rem;
}

.form-group input.readonly {
    background: rgba(245, 158, 11, 0.1);
    color: var(--warn);
    font-weight: 700;
}

.form-group input.roi-display {
    color: var(--accent);
    font-weight: 700;
}

.form-section {
    background: rgba(0, 0, 0, 0.2);
    border: 1px solid var(--border);
    border-radius: 14px;
    padding: 1.25rem;
    margin: 1rem 0;
}

.form-section h4 {
    color: var(--primary);
    margin-bottom: 1rem;
    font-size: 0.8rem;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.upload-box {
    border: 2px dashed var(--border);
    border-radius: 14px;
    padding: 2rem;
    text-align: center;
    cursor: pointer;
    transition: all 0.3s;
}

.upload-box:hover {
    border-color: var(--primary);
    background: rgba(99, 102, 241, 0.05);
    transform: scale(1.01);
}

.upload-box i {
    font-size: 2rem;
    color: var(--primary);
    margin-bottom: 0.75rem;
}

.upload-box span {
    display: block;
    color: var(--text-muted);
    font-size: 0.85rem;
}

#photo-preview {
    max-width: 150px;
    border-radius: 10px;
    margin-top: 0.75rem;
}

.audit-info {
    padding: 0.75rem;
    background: rgba(0, 0, 0, 0.2);
    border-radius: 8px;
    margin-top: 1rem;
    color: var(--text-muted);
    font-size: 0.75rem;
}

.modal-footer {
    padding: 1.25rem 1.5rem;
    border-top: 1px solid var(--border);
    display: flex;
    justify-content: flex-end;
    gap: 0.75rem;
    background: rgba(0, 0, 0, 0.2);
}

.btn-cancel,
.btn-save,
.btn-delete {
    padding: 0.75rem 1.5rem;
    border-radius: 10px;
    font-weight: 600;
    font-size: 0.9rem;
    cursor: pointer;
    transition: all 0.3s;
    border: none;
}

.btn-cancel {
    background: rgba(255, 255, 255, 0.05);
    color: var(--text-muted);
}

.btn-save {
    background: var(--primary);
    color: white;
}

.btn-delete {
    background: var(--danger);
    color: white;
}

.btn-save:hover,
.btn-delete:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 20px rgba(0, 0, 0, 0.3);
}

/* Photo Modal */
.photo-viewer {
    position: relative;
    max-width: 90%;
    max-height: 90%;
}

.photo-viewer img {
    max-width: 100%;
    max-height: 85vh;
    border-radius: 14px;
    box-shadow: var(--shadow);
}

.photo-close {
    position: absolute;
    top: -12px;
    right: -12px;
    width: 36px;
    height: 36px;
    border-radius: 50%;
    background: var(--danger);
    color: white;
    border: none;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s;
}

.photo-close:hover {
    transform: scale(1.1) rotate(90deg);
}

/* Utils */
.hidden {
    display: none !important;
}


.full-width {
    grid-column: span 3;
}

@media (max-width: 1200px) {
    .stats-grid {
        grid-template-columns: repeat(2, 1fr);
    }

    .form-row {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 768px) {
    .stats-grid {
        grid-template-columns: 1fr;
    }

    .form-row {
        grid-template-columns: 1fr;
    }

    .main-content {
        padding: 1rem;
    }

    .floating-shape {
        display: none;
    }
}