.page-auth,
.page-submit,
.page-admin {
    min-height: calc(100vh - 4rem);
    padding: 2rem;
    display: flex;
    justify-content: center;
    align-items: flex-start;
    background-color: var(--color-background);
    color: var(--color-on-background);
    font-family: "Lexend Deca", sans-serif;
    -webkit-font-smoothing: subpixel-antialiased;
    grid-column: 1 / -1;
    width: 100%;
    box-sizing: border-box;
}

.page-auth {
    align-items: center;
}

.auth-container {
    background: linear-gradient(145deg, rgba(39, 38, 44, 0.95), rgba(28, 27, 31, 0.98));
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 16px;
    padding: 2.5rem;
    width: 100%;
    max-width: 420px;
    box-sizing: border-box;
    margin: 0 auto;
    box-shadow: 
        0 20px 60px rgba(0, 0, 0, 0.5),
        0 0 0 1px rgba(255, 255, 255, 0.05) inset;
    backdrop-filter: blur(10px);
}

.auth-container h1 {
    text-align: center;
    margin-bottom: 2rem;
    font-size: 28px;
    font-weight: 700;
    letter-spacing: -0.5px;
    color: #fff;
}

.submit-container {
    background: linear-gradient(145deg, rgba(39, 38, 44, 0.95), rgba(28, 27, 31, 0.98));
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 16px;
    padding: 2rem;
    width: 100%;
    max-width: 700px;
    margin: 0 auto;
    box-sizing: border-box;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.5);
}

.admin-container {
    background: linear-gradient(145deg, rgba(39, 38, 44, 0.95), rgba(28, 27, 31, 0.98));
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 16px;
    padding: 2rem;
    width: 100%;
    max-width: 1100px;
    margin: 0 auto;
    box-sizing: border-box;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.5);
}

.submit-container h1,
.admin-container h1 {
    font-size: 24px;
    font-weight: 700;
    letter-spacing: -0.5px;
    margin: 0;
    color: #fff;
}

.auth-form,
.submit-form {
    display: flex;
    flex-direction: column;
    gap: 1.25rem;
}

.form-group {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.form-group label {
    font-weight: 600;
    font-size: 14px;
    color: rgba(255, 255, 255, 0.8);
    text-transform: uppercase;
    letter-spacing: 0.8px;
}

.form-group input,
.form-group select {
    padding: 0.875rem 1rem;
    border: 1px solid rgba(255, 255, 255, 0.12);
    border-radius: 10px;
    background: rgba(0, 0, 0, 0.3);
    color: var(--color-on-background);
    font-size: 15px;
    font-family: "Lexend Deca", sans-serif;
    font-weight: 400;
    letter-spacing: 0.2px;
    transition: all 0.2s ease;
}

.form-group input:hover,
.form-group select:hover {
    border-color: rgba(255, 255, 255, 0.2);
    background: rgba(0, 0, 0, 0.4);
}

.form-group input:focus,
.form-group select:focus {
    outline: none;
    border-color: rgba(255, 255, 255, 0.4);
    background: rgba(0, 0, 0, 0.5);
    box-shadow: 0 0 0 3px rgba(255, 255, 255, 0.08);
}

.form-group input::placeholder {
    color: rgba(255, 255, 255, 0.35);
}

.field-hint {
    font-size: 12px;
    color: rgba(255, 255, 255, 0.5);
    font-style: italic;
    margin-top: 0.25rem;
}

.proof-link {
    color: #4fc3f7;
    text-decoration: none;
    font-weight: 500;
}

.proof-link:hover {
    color: #81d4fa;
    text-decoration: underline;
}

.form-group select {
    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 12 12'%3E%3Cpath fill='%23ffffff' fill-opacity='0.5' d='M6 8L1 3h10z'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 1rem center;
    padding-right: 2.5rem;
}

.form-group select option {
    background: #1c1b1f;
    color: white;
    padding: 0.5rem;
}

.checkbox-group {
    flex-direction: row;
    align-items: center;
    gap: 0.75rem;
    padding: 0.75rem 1rem;
    background: rgba(0, 0, 0, 0.2);
    border-radius: 10px;
    border: 1px solid rgba(255, 255, 255, 0.08);
    cursor: pointer;
    transition: all 0.2s ease;
}

.checkbox-group:hover {
    background: rgba(0, 0, 0, 0.3);
    border-color: rgba(255, 255, 255, 0.15);
}

.checkbox-group input[type="checkbox"] {
    width: 20px;
    height: 20px;
    cursor: pointer;
    accent-color: white;
}

.checkbox-group label {
    text-transform: none;
    font-size: 1rem;
    color: var(--color-on-background);
    cursor: pointer;
}

.auth-btn,
.submit-btn {
    padding: 1rem 1.5rem;
    background: white;
    color: #1c1b1f;
    border: none;
    border-radius: 10px;
    font-size: 15px;
    font-weight: 700;
    font-family: "Lexend Deca", sans-serif;
    letter-spacing: 0.3px;
    cursor: pointer;
    transition: all 0.2s ease;
    text-align: center;
    text-decoration: none;
    display: inline-block;
    margin-top: 0.5rem;
    box-shadow: 0 4px 15px rgba(255, 255, 255, 0.15);
}

.auth-btn:hover,
.submit-btn:hover {
    background: #f0f0f0;
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(255, 255, 255, 0.2);
}

.auth-btn:active,
.submit-btn:active {
    transform: translateY(0);
}

.auth-btn:disabled,
.submit-btn:disabled {
    opacity: 0.5;
    cursor: not-allowed;
    transform: none;
    box-shadow: none;
}

.logout-btn {
    padding: 0.5rem 1rem;
    background: transparent;
    color: rgba(255, 255, 255, 0.6);
    border: 1px solid rgba(255, 255, 255, 0.2);
    border-radius: 8px;
    font-family: "Lexend Deca", sans-serif;
    font-size: 13px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s ease;
}

.logout-btn:hover {
    background: rgba(255, 100, 100, 0.15);
    border-color: rgba(255, 100, 100, 0.5);
    color: #ff6b6b;
}

.error-message {
    color: #ff6b6b;
    background: rgba(255, 107, 107, 0.12);
    padding: 0.875rem 1rem;
    border-radius: 10px;
    font-family: "Lexend Deca", sans-serif;
    font-size: 14px;
    font-weight: 500;
    border: 1px solid rgba(255, 107, 107, 0.2);
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.error-message::before {
    content: "⚠";
}

.success-message {
    color: #6bffa1;
    background: rgba(107, 255, 161, 0.12);
    padding: 0.875rem 1rem;
    border-radius: 10px;
    font-family: "Lexend Deca", sans-serif;
    font-size: 14px;
    font-weight: 500;
    border: 1px solid rgba(107, 255, 161, 0.2);
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.success-message::before {
    content: "✓";
}

.auth-link {
    text-align: center;
    margin-top: 1.75rem;
    padding-top: 1.5rem;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    color: rgba(255, 255, 255, 0.5);
    font-size: 14px;
}

.auth-link a {
    color: white;
    text-decoration: none;
    font-weight: 600;
    transition: opacity 0.2s;
}

.auth-link a:hover {
    opacity: 0.8;
    text-decoration: underline;
}

.login-prompt,
.access-denied {
    text-align: center;
    padding: 3rem 2rem;
}

.login-prompt p,
.access-denied p {
    margin-bottom: 1.5rem;
    color: rgba(255, 255, 255, 0.6);
    font-size: 16px;
    font-weight: 400;
}

.submit-header,
.admin-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 2rem;
    padding-bottom: 1.5rem;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
    flex-wrap: wrap;
    gap: 1rem;
}

.user-info {
    display: flex;
    align-items: center;
    gap: 1rem;
    color: rgba(255, 255, 255, 0.6);
    font-size: 14px;
}

.user-info strong {
    color: white;
    font-weight: 700;
}

.my-submissions {
    margin-top: 2.5rem;
    padding-top: 2rem;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
}

.my-submissions h2 {
    margin-bottom: 1.25rem;
    font-size: 20px;
    font-weight: 700;
    letter-spacing: -0.3px;
}

.submissions-table,
.admin-table {
    width: 100%;
    border-collapse: separate;
    border-spacing: 0;
    margin-top: 1rem;
}

.submissions-table th,
.admin-table th {
    font-family: "Lexend Deca", sans-serif;
    font-weight: 700;
    color: rgba(255, 255, 255, 0.6);
    font-size: 12px;
    text-transform: uppercase;
    letter-spacing: 1px;
    padding: 1rem;
    text-align: left;
    background: rgba(0, 0, 0, 0.2);
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.submissions-table th:first-child,
.admin-table th:first-child {
    border-radius: 8px 0 0 0;
}

.submissions-table th:last-child,
.admin-table th:last-child {
    border-radius: 0 8px 0 0;
}

.submissions-table td,
.admin-table td {
    padding: 1rem;
    border-bottom: 1px solid rgba(255, 255, 255, 0.06);
    vertical-align: middle;
    font-family: "Lexend Deca", sans-serif;
    font-size: 14px;
    font-weight: 400;
}

.submissions-table tbody tr,
.admin-table tbody tr {
    transition: background 0.2s ease;
}

.submissions-table tbody tr:hover,
.admin-table tbody tr:hover {
    background: rgba(255, 255, 255, 0.03);
}

.submissions-table tbody tr:last-child td,
.admin-table tbody tr:last-child td {
    border-bottom: none;
}

.status-badge {
    padding: 0.4rem 0.875rem;
    border-radius: 6px;
    font-family: "Lexend Deca", sans-serif;
    font-size: 11px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 80px;
}

.status-pending,
.status-badge.status-pending {
    color: #f5c842;
    background: rgba(245, 200, 66, 0.1);
    border: 1px solid rgba(245, 200, 66, 0.25);
}

.status-approved,
.status-badge.status-approved {
    color: #4ade80;
    background: rgba(74, 222, 128, 0.1);
    border: 1px solid rgba(74, 222, 128, 0.25);
}

.status-rejected,
.status-badge.status-rejected {
    color: #f87171;
    background: rgba(248, 113, 113, 0.1);
    border: 1px solid rgba(248, 113, 113, 0.25);
}

.rejection-reason-badge {
    font-size: 11px;
    color: rgba(248, 113, 113, 0.8);
    background: rgba(248, 113, 113, 0.08);
    padding: 0.3rem 0.6rem;
    border-radius: 4px;
    max-width: 200px;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    cursor: help;
}

.reject-modal {
    max-width: 420px;
    border: 1px solid rgba(239, 68, 68, 0.2);
    overflow: hidden;
}

.reject-close {
    position: absolute;
    top: 1rem;
    right: 1rem;
    z-index: 10;
}

.reject-modal-content {
    padding: 2rem;
}

.reject-header {
    text-align: center;
    margin-bottom: 1.5rem;
}

.reject-icon-wrapper {
    width: 64px;
    height: 64px;
    margin: 0 auto 1rem;
    background: rgba(239, 68, 68, 0.15);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
}

.reject-icon-wrapper svg {
    width: 32px;
    height: 32px;
    color: #ef4444;
}

.reject-header h2 {
    font-family: "Lexend Deca", sans-serif;
    font-size: 22px;
    font-weight: 700;
    color: white;
    margin: 0 0 0.5rem 0;
}

.reject-subtitle {
    font-size: 14px;
    color: rgba(255, 255, 255, 0.5);
    margin: 0;
}

.reject-details {
    background: rgba(0, 0, 0, 0.25);
    border-radius: 10px;
    padding: 1rem;
    margin-bottom: 1.5rem;
}

.reject-detail-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 0.5rem 0;
}

.reject-detail-item:not(:last-child) {
    border-bottom: 1px solid rgba(255, 255, 255, 0.06);
}

.detail-label {
    font-size: 13px;
    color: rgba(255, 255, 255, 0.5);
    font-weight: 500;
}

.detail-value {
    font-size: 14px;
    color: white;
    font-weight: 600;
}

.reject-reason-section {
    margin-bottom: 1.5rem;
}

.reject-reason-section label {
    display: block;
    font-size: 14px;
    font-weight: 600;
    color: rgba(255, 255, 255, 0.9);
    margin-bottom: 0.5rem;
}

.optional-tag {
    font-weight: 400;
    color: rgba(255, 255, 255, 0.4);
}

.reject-reason-section textarea {
    width: 100%;
    padding: 0.875rem 1rem;
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 10px;
    background: rgba(0, 0, 0, 0.25);
    color: white;
    font-family: "Lexend Deca", sans-serif;
    font-size: 14px;
    resize: vertical;
    min-height: 80px;
    transition: all 0.2s ease;
}

.reject-reason-section textarea:focus {
    outline: none;
    border-color: rgba(239, 68, 68, 0.4);
    background: rgba(0, 0, 0, 0.35);
}

.reject-reason-section textarea::placeholder {
    color: rgba(255, 255, 255, 0.3);
}

.reject-actions {
    display: flex;
    gap: 0.75rem;
}

.reject-cancel-btn {
    flex: 1;
    padding: 0.875rem 1rem;
    background: rgba(255, 255, 255, 0.08);
    color: rgba(255, 255, 255, 0.8);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 10px;
    font-family: "Lexend Deca", sans-serif;
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s ease;
}

.reject-cancel-btn:hover {
    background: rgba(255, 255, 255, 0.12);
    color: white;
}

.reject-confirm-btn {
    flex: 1;
    padding: 0.875rem 1rem;
    background: #dc2626;
    color: white;
    border: none;
    border-radius: 10px;
    font-family: "Lexend Deca", sans-serif;
    font-size: 14px;
    font-weight: 700;
    cursor: pointer;
    transition: all 0.2s ease;
}

.reject-confirm-btn:hover:not(:disabled) {
    background: #ef4444;
}

.reject-confirm-btn:disabled {
    opacity: 0.5;
    cursor: not-allowed;
}

.status-cell {
    vertical-align: middle;
    text-align: center;
}

.status-wrapper {
    display: inline-flex;
    flex-direction: column;
    align-items: center;
    gap: 0.5rem;
}

.rejection-info {
    background: linear-gradient(135deg, rgba(220, 38, 38, 0.12), rgba(185, 28, 28, 0.08));
    border: 1px solid rgba(248, 113, 113, 0.2);
    border-radius: 8px;
    padding: 0.625rem 0.875rem;
    text-align: center;
    max-width: 200px;
}

.rejection-info-header {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.4rem;
    font-size: 10px;
    font-weight: 700;
    color: #f87171;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    margin-bottom: 0.25rem;
}

.rejection-icon {
    font-size: 12px;
    opacity: 0.9;
}

.rejection-message {
    margin: 0;
    font-size: 12px;
    color: rgba(255, 255, 255, 0.75);
    line-height: 1.4;
    word-break: break-word;
}

.submissions-table tr.has-rejection td {
    padding-top: 0.875rem;
    padding-bottom: 0.875rem;
}

.status-actions-header {
    text-align: center !important;
}

.status-actions-cell {
    text-align: center;
}

.status-actions-wrapper {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 1rem;
}

.action-buttons {
    display: flex;
    gap: 0.5rem;
}

.proof-link-btn {
    display: inline-flex;
    align-items: center;
    gap: 0.4rem;
    padding: 0.4rem 0.75rem;
    background: rgba(255, 255, 255, 0.08);
    border: 1px solid rgba(255, 255, 255, 0.12);
    border-radius: 6px;
    color: rgba(255, 255, 255, 0.85);
    font-family: "Lexend Deca", sans-serif;
    font-size: 12px;
    font-weight: 500;
    text-decoration: none;
    transition: all 0.2s ease;
}

.proof-link-btn:hover {
    background: rgba(255, 255, 255, 0.12);
    border-color: rgba(255, 255, 255, 0.2);
    color: white;
    transform: translateY(-1px);
}

.proof-icon {
    font-size: 10px;
    opacity: 0.8;
}

.no-submissions,
.no-data {
    text-align: center;
    color: rgba(255, 255, 255, 0.5);
    padding: 3rem 2rem;
    background: rgba(0, 0, 0, 0.2);
    border-radius: 12px;
    border: 1px dashed rgba(255, 255, 255, 0.1);
    font-size: 15px;
    font-weight: 400;
}

.loading {
    text-align: center;
    color: rgba(255, 255, 255, 0.5);
    padding: 3rem 2rem;
    font-size: 15px;
    font-weight: 400;
}

.admin-tabs {
    display: flex;
    gap: 0.5rem;
    margin-bottom: 1.5rem;
    background: rgba(0, 0, 0, 0.2);
    padding: 0.5rem;
    border-radius: 12px;
}

.tab-btn {
    flex: 1;
    padding: 0.875rem 1.5rem;
    background: transparent;
    color: rgba(255, 255, 255, 0.5);
    border: none;
    border-radius: 8px;
    font-family: "Lexend Deca", sans-serif;
    font-size: 14px;
    font-weight: 600;
    letter-spacing: 0.3px;
    cursor: pointer;
    transition: all 0.2s ease;
}

.tab-btn:hover {
    color: rgba(255, 255, 255, 0.8);
    background: rgba(255, 255, 255, 0.05);
}

.tab-btn.active {
    color: #1c1b1f;
    background: white;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.2);
}

.admin-section {
    margin-top: 1rem;
}

.filter-bar {
    display: flex;
    align-items: center;
    gap: 1rem;
    margin-bottom: 1.5rem;
    padding: 1rem;
    background: rgba(0, 0, 0, 0.2);
    border-radius: 10px;
}

.filter-bar label {
    color: rgba(255, 255, 255, 0.6);
    font-size: 13px;
    font-weight: 600;
}

.filter-bar select {
    padding: 0.625rem 2rem 0.625rem 1rem;
    border: 1px solid rgba(255, 255, 255, 0.15);
    border-radius: 8px;
    background: rgba(0, 0, 0, 0.3);
    color: white;
    font-family: "Lexend Deca", sans-serif;
    font-size: 14px;
    font-weight: 400;
    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 12 12'%3E%3Cpath fill='%23ffffff' fill-opacity='0.5' d='M6 8L1 3h10z'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 0.75rem center;
}

.filter-bar select:focus {
    outline: none;
    border-color: rgba(255, 255, 255, 0.3);
}

.admin-table .actions {
    display: flex;
    gap: 0.5rem;
    justify-content: flex-start;
}

.approve-btn,
.reject-btn {
    width: 36px;
    height: 36px;
    padding: 0;
    border: none;
    border-radius: 8px;
    cursor: pointer;
    font-family: "Lexend Deca", sans-serif;
    font-weight: 700;
    font-size: 14px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    transition: all 0.2s ease;
}

.approve-btn {
    background: rgba(74, 222, 128, 0.15);
    color: #4ade80;
    border: 1px solid rgba(74, 222, 128, 0.3);
}

.approve-btn:hover {
    background: rgba(74, 222, 128, 0.25);
    border-color: rgba(74, 222, 128, 0.5);
    transform: scale(1.05);
    box-shadow: 0 0 12px rgba(74, 222, 128, 0.3);
}

.reject-btn {
    background: rgba(248, 113, 113, 0.15);
    color: #f87171;
    border: 1px solid rgba(248, 113, 113, 0.3);
}

.reject-btn:hover {
    background: rgba(248, 113, 113, 0.25);
    border-color: rgba(248, 113, 113, 0.5);
    transform: scale(1.05);
    box-shadow: 0 0 12px rgba(248, 113, 113, 0.3);
}

.promote-btn,
.demote-btn {
    padding: 0.5rem 0.875rem;
    border: none;
    border-radius: 6px;
    cursor: pointer;
    font-family: "Lexend Deca", sans-serif;
    font-weight: 700;
    font-size: 12px;
    letter-spacing: 0.3px;
    transition: all 0.2s ease;
    background: rgba(255, 255, 255, 0.1);
    color: white;
    border: 1px solid rgba(255, 255, 255, 0.2);
}

.promote-btn:hover {
    background: rgba(255, 255, 255, 0.15);
    transform: translateY(-1px);
}

.demote-btn {
    background: rgba(255, 193, 7, 0.15);
    color: #ffc107;
    border: 1px solid rgba(255, 193, 7, 0.3);
}

.demote-btn:hover {
    background: rgba(255, 193, 7, 0.25);
    transform: translateY(-1px);
}

.role-admin {
    color: rgba(255, 255, 255, 0.7);
    font-weight: 500;
    font-size: 13px;
}

.role-user {
    color: rgba(255, 255, 255, 0.5);
    font-size: 13px;
}

.processed,
.current-user {
    color: rgba(255, 255, 255, 0.4);
    font-size: 0.85rem;
    font-style: italic;
}

.video-link {
    color: white;
    text-decoration: none;
    padding: 0.35rem 0.75rem;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 6px;
    font-size: 0.85rem;
    transition: all 0.2s ease;
    display: inline-block;
}

.video-link:hover {
    background: rgba(255, 255, 255, 0.15);
}

.admin-link {
    background: rgba(255, 255, 255, 0.15) !important;
    border: 1px solid rgba(255, 255, 255, 0.2) !important;
}

@media screen and (max-width: 1024px) {
    .page-auth,
    .page-submit,
    .page-admin {
        padding: 1.5rem;
    }
    
    .admin-container {
        max-width: 100%;
        width: 100%;
    }
    
    .submissions-table,
    .admin-table {
        width: 100%;
        display: table;
    }
    
    .admin-tabs-wrapper {
        overflow-x: auto;
        -webkit-overflow-scrolling: touch;
    }
}

@media screen and (max-width: 768px) {
    .page-auth,
    .page-submit,
    .page-admin {
        padding: 1rem;
        align-items: flex-start;
    }
    
    .page-auth {
        align-items: center;
        padding-top: 2rem;
    }
    
    .auth-container {
        padding: 2rem 1.5rem;
        border-radius: 12px;
        margin: 0 auto;
    }
    
    .auth-container h1 {
        font-size: 1.5rem;
    }
    
    .submit-container,
    .admin-container {
        padding: 1.5rem;
        border-radius: 12px;
    }
    
    .submit-header,
    .admin-header {
        flex-direction: column;
        align-items: flex-start;
        gap: 1rem;
    }
    
    .user-info {
        width: 100%;
        justify-content: space-between;
        padding: 0.75rem 1rem;
        background: rgba(0, 0, 0, 0.2);
        border-radius: 8px;
    }
    
    .admin-tabs {
        flex-direction: column;
    }
    
    .tab-btn {
        text-align: center;
    }
    
    .filter-bar {
        flex-direction: column;
        align-items: stretch;
        gap: 0.75rem;
    }
    
    .filter-bar select {
        width: 100%;
    }
    
    .submissions-table,
    .admin-table {
        font-size: 0.875rem;
        width: 100%;
        table-layout: fixed;
    }
    
    .admin-container {
        overflow-x: auto;
    }
    
    .submissions-table th,
    .submissions-table td,
    .admin-table th,
    .admin-table td {
        padding: 0.75rem 0.5rem;
        word-wrap: break-word;
        overflow-wrap: break-word;
    }
    
    .admin-table .actions {
        flex-direction: column;
        gap: 0.375rem;
    }
    
    .approve-btn,
    .reject-btn,
    .promote-btn,
    .demote-btn {
        padding: 0.5rem;
        font-size: 0.8rem;
        width: 100%;
        text-align: center;
    }
}

@media screen and (max-width: 480px) {
    .page-auth,
    .page-submit,
    .page-admin {
        padding: 0.75rem;
    }
    
    .auth-container {
        padding: 1.75rem 1.25rem;
        border-radius: 10px;
    }
    
    .auth-container h1 {
        font-size: 1.35rem;
        margin-bottom: 1.5rem;
    }
    
    .submit-container,
    .admin-container {
        padding: 1.25rem;
        border-radius: 10px;
    }
    
    .submit-container h1,
    .admin-container h1 {
        font-size: 1.25rem;
    }
    
    .form-group input,
    .form-group select {
        padding: 0.75rem;
        font-size: 16px;
    }
    
    .auth-btn,
    .submit-btn {
        padding: 0.875rem 1rem;
        font-size: 0.95rem;
    }
    
    .auth-link {
        font-size: 0.85rem;
    }
    
    .my-submissions h2 {
        font-size: 1.1rem;
    }
    
    .submissions-table thead,
    .admin-table thead {
        display: none;
    }
    
    .submissions-table tbody tr,
    .admin-table tbody tr {
        display: flex;
        flex-direction: column;
        background: rgba(0, 0, 0, 0.2);
        border-radius: 10px;
        margin-bottom: 0.75rem;
        padding: 1rem;
        border: 1px solid rgba(255, 255, 255, 0.06);
    }
    
    .submissions-table tbody tr:hover,
    .admin-table tbody tr:hover {
        background: rgba(0, 0, 0, 0.25);
    }
    
    .submissions-table td,
    .admin-table td {
        display: flex;
        justify-content: space-between;
        align-items: center;
        padding: 0.5rem 0;
        border-bottom: 1px solid rgba(255, 255, 255, 0.05);
        gap: 1rem;
    }
    
    .submissions-table td:last-child,
    .admin-table td:last-child {
        border-bottom: none;
        padding-top: 0.75rem;
    }
    
    .submissions-table td::before,
    .admin-table td::before {
        content: attr(data-label);
        font-weight: 600;
        color: rgba(255, 255, 255, 0.5);
        font-size: 0.75rem;
        text-transform: uppercase;
        flex-shrink: 0;
    }
    
    .admin-table .actions {
        flex-direction: row;
        width: 100%;
        justify-content: flex-end;
    }
    
    .admin-table .role-actions {
        justify-content: space-between;
    }
    
    .admin-table .role-select {
        max-width: 120px;
    }
    
    .admin-table .current-user {
        color: rgba(255, 255, 255, 0.5);
        font-style: italic;
    }
}

@media screen and (max-width: 360px) {
    .auth-container {
        padding: 1.5rem 1rem;
    }
    
    .auth-container h1 {
        font-size: 1.25rem;
    }
    
    .form-group label {
        font-size: 0.8rem;
    }
    
    .user-info {
        flex-direction: column;
        align-items: flex-start;
        gap: 0.5rem;
    }
    
    .user-info .logout-btn {
        width: 100%;
    }
}

@media screen and (max-height: 500px) and (orientation: landscape) {
    .page-auth {
        align-items: flex-start;
        padding-top: 1rem;
    }
    
    .auth-container {
        padding: 1.5rem;
    }
    
    .auth-container h1 {
        margin-bottom: 1rem;
    }
    
    .auth-form,
    .submit-form {
        gap: 0.75rem;
    }
}

.section-header {
    display: flex;
    justify-content: flex-end;
    margin-bottom: 1.5rem;
}

.add-btn {
    padding: 0.75rem 1.25rem;
    background: white;
    color: #1c1b1f;
    border: none;
    border-radius: 8px;
    font-family: "Lexend Deca", sans-serif;
    font-size: 14px;
    font-weight: 700;
    cursor: pointer;
    transition: all 0.2s ease;
}

.add-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 15px rgba(255, 255, 255, 0.2);
}

.levels-list {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.level-card {
    display: flex;
    align-items: center;
    gap: 1rem;
    padding: 1rem 1.25rem;
    background: rgba(0, 0, 0, 0.2);
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 10px;
    transition: all 0.2s ease;
}

.level-card:hover {
    background: rgba(0, 0, 0, 0.3);
    border-color: rgba(255, 255, 255, 0.12);
}

.level-card.unranked {
    opacity: 0.7;
}

.level-rank {
    min-width: 50px;
    font-family: "Lexend Deca", sans-serif;
    font-size: 18px;
    font-weight: 700;
    color: rgba(255, 255, 255, 0.6);
    text-align: center;
}

.level-info {
    flex: 1;
    min-width: 0;
}

.level-name {
    font-family: "Lexend Deca", sans-serif;
    font-size: 15px;
    font-weight: 600;
    color: white;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.level-meta {
    display: flex;
    gap: 1rem;
    font-size: 13px;
    color: rgba(255, 255, 255, 0.5);
    margin-top: 0.25rem;
}

.level-id {
    color: rgba(255, 255, 255, 0.4);
}

.level-actions {
    display: flex;
    gap: 0.5rem;
    flex-shrink: 0;
}

.move-btn,
.edit-btn,
.delete-btn {
    width: 36px;
    height: 36px;
    border: 1px solid rgba(255, 255, 255, 0.15);
    border-radius: 6px;
    background: rgba(0, 0, 0, 0.2);
    color: rgba(255, 255, 255, 0.6);
    font-size: 14px;
    cursor: pointer;
    transition: all 0.2s ease;
    display: flex;
    align-items: center;
    justify-content: center;
}

.move-btn:hover:not(:disabled),
.edit-btn:hover {
    background: rgba(255, 255, 255, 0.1);
    border-color: rgba(255, 255, 255, 0.3);
    color: white;
}

.move-btn:disabled {
    opacity: 0.3;
    cursor: not-allowed;
}

.delete-btn:hover {
    background: rgba(255, 107, 107, 0.15);
    border-color: rgba(255, 107, 107, 0.5);
    color: #ff6b6b;
}

.unranked-section {
    margin-top: 2rem;
    padding-top: 1.5rem;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
}

.unranked-section h3 {
    font-family: "Lexend Deca", sans-serif;
    font-size: 16px;
    font-weight: 600;
    color: rgba(255, 255, 255, 0.5);
    margin-bottom: 1rem;
}

.modal-overlay {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.8);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 1000;
    padding: 1rem;
}

.modal {
    background: linear-gradient(145deg, rgba(39, 38, 44, 0.98), rgba(28, 27, 31, 1));
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 16px;
    width: 100%;
    max-width: 600px;
    max-height: 90vh;
    overflow-y: auto;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.5);
}

.modal-sm {
    max-width: 400px;
}

.modal-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 1.5rem;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.modal-header h2 {
    font-family: "Lexend Deca", sans-serif;
    font-size: 20px;
    font-weight: 700;
    color: white;
    margin: 0;
}

.modal-close {
    width: 36px;
    height: 36px;
    border: none;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 50%;
    color: white;
    font-size: 24px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.2s ease;
}

.modal-close:hover {
    background: rgba(255, 255, 255, 0.2);
}

.modal-form {
    padding: 1.5rem;
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.modal-body {
    padding: 1.5rem;
}

.modal-body p {
    margin: 0 0 0.75rem;
    font-size: 15px;
    color: rgba(255, 255, 255, 0.8);
}

.warning-text {
    color: #ff6b6b !important;
    font-size: 14px !important;
}

.form-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1rem;
}

.form-row .form-group {
    min-width: 0;
}

.form-row .form-group input {
    width: 100%;
    box-sizing: border-box;
}

.modal-form textarea {
    padding: 0.875rem 1rem;
    border: 1px solid rgba(255, 255, 255, 0.12);
    border-radius: 10px;
    background: rgba(0, 0, 0, 0.3);
    color: white;
    font-family: "Lexend Deca", sans-serif;
    font-size: 15px;
    resize: vertical;
    min-height: 80px;
    transition: all 0.2s ease;
}

.modal-form textarea:focus {
    outline: none;
    border-color: rgba(255, 255, 255, 0.4);
    background: rgba(0, 0, 0, 0.5);
}

.modal-actions {
    display: flex;
    justify-content: flex-end;
    gap: 1rem;
    padding: 1.5rem;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
}

.level-modal {
    max-width: 500px;
}

.level-modal-actions {
    display: flex;
    justify-content: center;
    gap: 1rem;
    padding: 1.5rem;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    flex-wrap: wrap;
}

.level-modal-actions .cancel-btn,
.level-modal-actions .submit-btn {
    flex: 1;
    max-width: 160px;
    min-width: 120px;
    padding: 0.875rem 1.5rem;
    margin-top: 0;
    box-shadow: none;
}

.level-modal-actions .cancel-btn {
    background: rgba(255, 255, 255, 0.08);
    border: 1px solid rgba(255, 255, 255, 0.15);
    color: rgba(255, 255, 255, 0.8);
}

.level-modal-actions .cancel-btn:hover {
    background: rgba(255, 255, 255, 0.12);
    border-color: rgba(255, 255, 255, 0.25);
    color: white;
}

.level-modal-actions .submit-btn {
    border-radius: 8px;
}

.level-modal .modal-form textarea {
    resize: none;
}

.image-upload-zone {
    border: 2px dashed rgba(255, 255, 255, 0.15);
    border-radius: 12px;
    cursor: pointer;
    transition: all 0.3s ease;
    background: rgba(255, 255, 255, 0.02);
    aspect-ratio: 16 / 9;
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
    overflow: hidden;
}

.image-upload-zone:hover {
    border-color: rgba(255, 255, 255, 0.3);
    background: rgba(255, 255, 255, 0.04);
}

.image-upload-zone.dragging {
    border-color: #7c3aed;
    background: rgba(124, 58, 237, 0.1);
    border-style: solid;
}

.image-upload-zone.has-image {
    border-style: solid;
    border-color: rgba(255, 255, 255, 0.1);
}

.image-upload-zone .upload-placeholder {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.75rem;
    color: rgba(255, 255, 255, 0.4);
    text-align: center;
    padding: 1rem;
}

.image-upload-zone .upload-icon-wrapper {
    width: 48px;
    height: 48px;
    border-radius: 12px;
    background: rgba(255, 255, 255, 0.05);
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s ease;
}

.image-upload-zone:hover .upload-icon-wrapper {
    background: rgba(255, 255, 255, 0.08);
    transform: scale(1.05);
}

.image-upload-zone .upload-icon-wrapper svg {
    width: 24px;
    height: 24px;
    stroke: rgba(255, 255, 255, 0.5);
}

.image-upload-zone .upload-text {
    font-size: 13px;
    font-weight: 500;
    color: rgba(255, 255, 255, 0.6);
}

.image-upload-zone .upload-hint {
    font-size: 11px;
    color: rgba(255, 255, 255, 0.35);
}

.image-upload-zone .image-preview {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
}

.image-upload-zone .image-preview img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.image-upload-zone .remove-image-btn {
    position: absolute;
    top: 8px;
    right: 8px;
    width: 28px;
    height: 28px;
    border-radius: 8px;
    background: rgba(0, 0, 0, 0.7);
    color: white;
    border: 1px solid rgba(255, 255, 255, 0.1);
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.2s ease;
    backdrop-filter: blur(4px);
}

.image-upload-zone .remove-image-btn svg {
    width: 14px;
    height: 14px;
}

.image-upload-zone .remove-image-btn:hover {
    background: rgba(255, 71, 87, 0.9);
    border-color: transparent;
    transform: scale(1.1);
}

.cancel-btn {
    padding: 0.75rem 1.5rem;
    background: transparent;
    color: rgba(255, 255, 255, 0.6);
    border: 1px solid rgba(255, 255, 255, 0.2);
    border-radius: 8px;
    font-family: "Lexend Deca", sans-serif;
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s ease;
}

.cancel-btn:hover {
    background: rgba(255, 255, 255, 0.05);
    border-color: rgba(255, 255, 255, 0.3);
    color: white;
}

.delete-confirm-btn {
    padding: 0.75rem 1.5rem;
    background: rgba(255, 107, 107, 0.2);
    color: #ff6b6b;
    border: 1px solid rgba(255, 107, 107, 0.4);
    border-radius: 8px;
    font-family: "Lexend Deca", sans-serif;
    font-size: 14px;
    font-weight: 700;
    cursor: pointer;
    transition: all 0.2s ease;
}

.delete-confirm-btn:hover:not(:disabled) {
    background: rgba(255, 107, 107, 0.3);
    border-color: rgba(255, 107, 107, 0.6);
}

.delete-confirm-btn:disabled {
    opacity: 0.5;
    cursor: not-allowed;
}

@media screen and (max-width: 768px) {
    .modal {
        max-height: 85vh;
    }
    
    .form-row {
        grid-template-columns: 1fr;
    }
    
    .modal-header {
        padding: 1rem;
    }
    
    .modal-form {
        padding: 1rem;
    }
    
    .modal-actions {
        padding: 1rem;
        flex-direction: column;
    }
    
    .modal-actions button {
        width: 100%;
    }
    
    .level-modal-actions {
        flex-direction: column;
        align-items: center;
        gap: 0.75rem;
        padding: 1rem;
    }
    
    .level-modal-actions .cancel-btn,
    .level-modal-actions .submit-btn {
        width: 100%;
        max-width: 100%;
        text-align: center;
        display: block;
    }
    
    .level-card {
        flex-wrap: wrap;
    }
    
    .level-info {
        flex: 1 1 calc(100% - 80px);
    }
    
    .level-actions {
        width: 100%;
        justify-content: flex-end;
        margin-top: 0.5rem;
        padding-top: 0.75rem;
        border-top: 1px solid rgba(255, 255, 255, 0.08);
    }
}

@media (-webkit-min-device-pixel-ratio: 2), (min-resolution: 192dpi) {
    .form-group input,
    .form-group select {
        -webkit-font-smoothing: antialiased;
    }
}

@media (prefers-reduced-motion: reduce) {
    .auth-btn,
    .submit-btn,
    .logout-btn,
    .tab-btn,
    .approve-btn,
    .reject-btn,
    .promote-btn,
    .demote-btn,
    .video-link,
    .form-group input,
    .form-group select {
        transition: none;
    }
    
    .auth-btn:hover,
    .submit-btn:hover,
    .approve-btn:hover,
    .reject-btn:hover,
    .promote-btn:hover,
    .demote-btn:hover {
        transform: none;
    }
}

.delete-submission-btn {
    width: 32px;
    height: 32px;
    border-radius: 6px;
    border: none;
    background: rgba(239, 68, 68, 0.15);
    color: #ef4444;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 14px;
    transition: all 0.2s ease;
}

.delete-submission-btn:hover {
    background: rgba(239, 68, 68, 0.25);
    transform: scale(1.05);
}

.delete-icon {
    background: rgba(239, 68, 68, 0.15) !important;
    color: #ef4444 !important;
}

.delete-confirm {
    background: linear-gradient(135deg, #ef4444 0%, #dc2626 100%) !important;
}

.delete-confirm:hover {
    background: linear-gradient(135deg, #dc2626 0%, #b91c1c 100%) !important;
}

.role-select {
    padding: 0.5rem 0.75rem;
    border-radius: 6px;
    border: 1px solid rgba(255, 255, 255, 0.1);
    background: rgba(39, 38, 44, 0.95);
    color: var(--color-on-background);
    font-size: 0.875rem;
    cursor: pointer;
    transition: all 0.2s ease;
    appearance: none;
    -webkit-appearance: none;
    -moz-appearance: none;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 12 12'%3E%3Cpath fill='%23888' d='M6 8L1 3h10z'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 0.5rem center;
    padding-right: 1.75rem;
}

.role-select:hover {
    border-color: rgba(255, 255, 255, 0.2);
    background-color: rgba(50, 48, 56, 0.95);
}

.role-select:focus {
    outline: none;
    border-color: var(--color-primary);
}

.role-select option {
    background: #27262c;
    color: var(--color-on-background);
    padding: 0.5rem;
}

.role-editor {
    color: #60a5fa;
}

.role-actions {
    min-width: 120px;
}

@media screen and (max-width: 480px) {
    .modal-overlay {
        padding: 0.5rem;
    }
    
    .modal,
    .level-modal {
        max-width: 100%;
        width: 100%;
        max-height: 90vh;
        margin: auto;
    }
    
    .modal-header {
        padding: 1rem;
    }
    
    .modal-header h2 {
        font-size: 1.1rem;
    }
    
    .modal-form {
        padding: 1rem;
    }
    
    .level-modal-actions {
        padding: 1rem;
        flex-direction: column;
        align-items: center;
        gap: 0.75rem;
    }
    
    .level-modal-actions .cancel-btn,
    .level-modal-actions .submit-btn {
        max-width: 100%;
        width: 100%;
        text-align: center;
        display: block;
    }
    
    .image-upload-zone {
        aspect-ratio: 16 / 9;
    }
    
    .image-upload-zone .upload-placeholder {
        padding: 0.75rem;
    }
    
    .image-upload-zone .upload-text {
        font-size: 0.85rem;
    }
    
    .image-upload-zone .upload-hint {
        font-size: 0.7rem;
    }
    
    .admin-table tbody tr {
        padding: 0.75rem;
    }
    
    .admin-table td {
        font-size: 0.85rem;
        word-break: break-word;
    }
    
    .admin-table td::before {
        min-width: 80px;
    }
}

/* Profile Page Styles */
.profile-container {
    max-width: 480px;
}

.profile-content {
    display: flex;
    flex-direction: column;
    gap: 2rem;
}

.profile-info {
    display: flex;
    align-items: center;
    gap: 1.5rem;
    padding-bottom: 1.5rem;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.profile-avatar {
    width: 80px;
    height: 80px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.1);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 2.5rem;
    flex-shrink: 0;
}

.profile-flag {
    font-size: 2.5rem;
}

.profile-flag-universal {
    opacity: 0.7;
}

.profile-details {
    flex: 1;
    min-width: 0;
}

.profile-details h2 {
    font-size: 1.5rem;
    font-weight: 700;
    margin: 0 0 0.25rem 0;
    color: #fff;
    word-break: break-word;
}

.profile-email {
    color: rgba(255, 255, 255, 0.6);
    font-size: 0.9rem;
    margin: 0 0 0.5rem 0;
    word-break: break-all;
}

.profile-role {
    font-size: 0.85rem;
    color: rgba(255, 255, 255, 0.5);
    margin: 0;
}

.profile-role .role-admin {
    color: #ff6b6b;
    font-weight: 600;
}

.profile-role .role-editor {
    color: #4fc3f7;
    font-weight: 600;
}

.profile-role .role-user {
    color: rgba(255, 255, 255, 0.7);
}

.flag-select-wrapper {
    display: flex;
    align-items: center;
    gap: 0.75rem;
}

.flag-preview {
    font-size: 1.75rem;
    width: 40px;
    text-align: center;
    flex-shrink: 0;
}

.flag-select {
    flex: 1;
}

.profile-actions {
    padding-top: 1rem;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    display: flex;
    justify-content: center;
}

/* User Flag in Admin Table */
.user-flag-cell {
    text-align: center;
}

.user-flag {
    font-size: 1.25rem;
    display: flex;
    align-items: center;
    justify-content: center;
}

.user-flag-universal {
    opacity: 0.5;
}

.flag-img-table {
    width: 24px;
    height: 17px;
    object-fit: cover;
    border-radius: 2px;
    box-shadow: 0 1px 2px rgba(0, 0, 0, 0.3);
}

/* Users Admin Table */
.users-admin-table th:nth-child(2),
.users-admin-table td:nth-child(2) {
    width: 50px;
    text-align: center;
}

/* Flag Selection Modal */
.flag-modal {
    background: linear-gradient(145deg, rgba(39, 38, 44, 0.98), rgba(28, 27, 31, 1));
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 16px;
    width: 100%;
    max-width: 500px;
    max-height: 80vh;
    display: flex;
    flex-direction: column;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.5);
}

.flag-modal-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 1.25rem 1.5rem;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.flag-modal-header h2 {
    font-family: "Lexend Deca", sans-serif;
    font-size: 18px;
    font-weight: 700;
    color: white;
    margin: 0;
}

.flag-modal-search {
    padding: 1rem 1.5rem;
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
}

.flag-search-input {
    width: 100%;
    padding: 0.75rem 1rem;
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 8px;
    color: white;
    font-family: "Lexend Deca", sans-serif;
    font-size: 14px;
    outline: none;
    transition: border-color 200ms ease, background 200ms ease;
}

.flag-search-input:focus {
    border-color: rgba(255, 255, 255, 0.3);
    background: rgba(255, 255, 255, 0.08);
}

.flag-search-input::placeholder {
    color: rgba(255, 255, 255, 0.4);
}

.flag-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(140px, 1fr));
    gap: 0.5rem;
    padding: 1rem 1.5rem;
    overflow-y: auto;
    max-height: 50vh;
    /* Custom scrollbar */
    scrollbar-width: thin;
    scrollbar-color: rgba(255, 255, 255, 0.3) rgba(255, 255, 255, 0.05);
}

/* Webkit scrollbar for Chrome, Safari, Edge */
.flag-grid::-webkit-scrollbar {
    width: 8px;
}

.flag-grid::-webkit-scrollbar-track {
    background: rgba(255, 255, 255, 0.05);
    border-radius: 4px;
}

.flag-grid::-webkit-scrollbar-thumb {
    background: rgba(255, 255, 255, 0.2);
    border-radius: 4px;
    transition: background 200ms ease;
}

.flag-grid::-webkit-scrollbar-thumb:hover {
    background: rgba(255, 255, 255, 0.35);
}

.flag-option {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.625rem 0.75rem;
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 8px;
    cursor: pointer;
    transition: all 200ms ease;
    color: white;
}

.flag-option:hover {
    background: rgba(255, 255, 255, 0.1);
    border-color: rgba(255, 255, 255, 0.2);
}

.flag-option.selected {
    background: rgba(76, 175, 80, 0.2);
    border-color: rgba(76, 175, 80, 0.5);
}

.flag-emoji {
    font-size: 1.5rem;
    line-height: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    min-width: 28px;
}

.flag-img {
    width: 28px;
    height: 20px;
    object-fit: cover;
    border-radius: 3px;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.3);
}

.flag-img-nav {
    width: 24px;
    height: 17px;
    object-fit: cover;
    border-radius: 2px;
    box-shadow: 0 1px 2px rgba(0, 0, 0, 0.3);
}

.flag-globe {
    font-size: 1.5rem;
}

.flag-name {
    font-family: "Lexend Deca", sans-serif;
    font-size: 12px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    color: rgba(255, 255, 255, 0.9);
}

.flag-error {
    padding: 0.75rem 1.5rem;
    color: #f44336;
    font-size: 14px;
    text-align: center;
}

.flag-success {
    padding: 0.75rem 1.5rem;
    color: #4caf50;
    font-size: 14px;
    text-align: center;
}

@media screen and (max-width: 480px) {
    .flag-modal {
        max-width: calc(100vw - 2rem);
        max-height: 85vh;
    }
    
    .flag-grid {
        grid-template-columns: repeat(auto-fill, minmax(120px, 1fr));
        gap: 0.375rem;
        padding: 0.75rem 1rem;
    }
    
    .flag-option {
        padding: 0.5rem 0.625rem;
    }
    
    .flag-emoji {
        font-size: 1.25rem;
    }
    
    .flag-name {
        font-size: 11px;
    }
}
