/* ============================================
   SACC Doodles - Admin Dashboard Styles
   Custom styles for the admin interface
   ============================================ */

/* Variables matching Tailwind config */
:root {
    --brand-dark: rgb(22, 22, 22);
    --brand-darker: rgb(30, 30, 30);
    --brand-card: rgb(38, 38, 38);
    --brand-gold: rgb(186, 155, 121);
    --brand-gold-light: rgb(210, 180, 145);
    --text-white: #fff;
    --text-gray-100: #f3f4f6;
    --text-gray-300: #d1d5db;
    --text-gray-400: #9ca3af;
    --text-gray-500: #6b7280;
    --text-gray-600: #4b5563;
}

/* Global SVG defaults - prevent unsized SVGs from filling screen */
#main-content svg {
    max-width: 100%;
    height: auto;
}

#main-content svg:not([width]):not([height]) {
    width: 24px;
    height: 24px;
}

/* Page Header */
.admin-page-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 1.5rem;
    flex-wrap: wrap;
    gap: 1rem;
}

.admin-page-header h1 {
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--text-white);
    margin: 0;
}

.header-actions {
    display: flex;
    align-items: center;
    gap: 1rem;
    flex-wrap: wrap;
}

/* Search Box */
.search-box {
    position: relative;
    display: flex;
    align-items: center;
}

.search-box svg {
    position: absolute;
    left: 0.75rem;
    color: var(--text-gray-500);
    pointer-events: none;
}

.search-box input {
    padding: 0.5rem 0.75rem 0.5rem 2.25rem;
    background: var(--brand-card);
    border: 1px solid var(--brand-card);
    border-radius: 0.5rem;
    color: var(--text-gray-300);
    font-size: 0.875rem;
    min-width: 200px;
    transition: border-color 0.2s;
}

.search-box input:focus {
    outline: none;
    border-color: var(--brand-gold);
}

.search-box input::placeholder {
    color: var(--text-gray-500);
}

/* Buttons */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    padding: 0.5rem 1rem;
    font-size: 0.875rem;
    font-weight: 600;
    border-radius: 0.5rem;
    cursor: pointer;
    transition: all 0.2s;
    border: none;
}

.btn-primary {
    background: var(--brand-gold);
    color: var(--brand-dark);
}

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

.btn-secondary {
    background: var(--brand-card);
    color: var(--text-gray-300);
}

.btn-secondary:hover {
    background: var(--brand-darker);
}

.btn-danger {
    background: #ef4444;
    color: white;
}

.btn-danger:hover {
    background: #dc2626;
}

.btn-sm {
    padding: 0.375rem 0.75rem;
    font-size: 0.75rem;
}

.btn-icon {
    padding: 0.5rem;
    background: transparent;
    color: var(--text-gray-400);
}

.btn-icon:hover {
    color: var(--text-white);
    background: var(--brand-card);
}

/* Cards */
.admin-card {
    background: var(--brand-card);
    border-radius: 0.75rem;
    overflow: hidden;
    margin-bottom: 1.5rem;
}

.admin-card-header {
    padding: 1rem 1.5rem;
    border-bottom: 1px solid var(--brand-darker);
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.admin-card-header h2,
.admin-card-header h3 {
    font-size: 1rem;
    font-weight: 600;
    color: var(--text-white);
    margin: 0;
}

.admin-card-body {
    padding: 1.5rem;
}

.admin-card-body.no-padding {
    padding: 0;
}

/* Tables */
.table-responsive {
    overflow-x: auto;
}

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

.admin-table th,
.admin-table td {
    padding: 0.75rem 1rem;
    text-align: left;
    border-bottom: 1px solid var(--brand-darker);
}

.admin-table th {
    font-size: 0.75rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    color: var(--text-gray-500);
    background: var(--brand-darker);
}

.admin-table td {
    font-size: 0.875rem;
    color: var(--text-gray-300);
}

.admin-table tbody tr:hover {
    background: var(--brand-darker);
}

.admin-table .dog-cell,
.admin-table .item-cell {
    display: flex;
    align-items: center;
    gap: 0.75rem;
}

.admin-table .dog-cell img,
.admin-table .item-cell img {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    object-fit: cover;
    background: var(--brand-darker);
}

.admin-table .dog-cell .dog-name,
.admin-table .item-cell .item-name {
    font-weight: 500;
    color: var(--text-white);
}

.admin-table .actions {
    display: flex;
    gap: 0.5rem;
    justify-content: flex-end;
}

/* Empty State */
.admin-empty-state {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 3rem;
    text-align: center;
    color: var(--text-gray-500);
}

.admin-empty-state svg {
    margin-bottom: 1rem;
    opacity: 0.5;
}

.admin-empty-state p {
    margin: 0 0 1rem;
    font-size: 1rem;
}

/* Status Badges */
.status-badge {
    display: inline-flex;
    align-items: center;
    padding: 0.25rem 0.75rem;
    font-size: 0.75rem;
    font-weight: 500;
    border-radius: 9999px;
}

.status-badge.active,
.status-badge.available {
    background: rgba(34, 197, 94, 0.2);
    color: #4ade80;
}

.status-badge.reserved {
    background: rgba(59, 130, 246, 0.2);
    color: #60a5fa;
}

.status-badge.sold {
    background: rgba(168, 85, 247, 0.2);
    color: #c084fc;
}

.status-badge.retired,
.status-badge.inactive {
    background: rgba(107, 114, 128, 0.2);
    color: #9ca3af;
}

.status-badge.pending {
    background: rgba(234, 179, 8, 0.2);
    color: #fbbf24;
}

.status-badge.home {
    background: rgba(34, 197, 94, 0.2);
    color: #4ade80;
}

.status-badge.guardian {
    background: rgba(59, 130, 246, 0.2);
    color: #60a5fa;
}

/* Forms */
.form-group {
    margin-bottom: 1rem;
}

.form-group label {
    display: block;
    font-size: 0.875rem;
    font-weight: 500;
    color: var(--text-gray-400);
    margin-bottom: 0.375rem;
}

.form-group input,
.form-group select,
.form-group textarea {
    width: 100%;
    padding: 0.625rem 0.875rem;
    background: var(--brand-darker);
    border: 1px solid var(--brand-card);
    border-radius: 0.5rem;
    color: var(--text-white);
    font-size: 0.875rem;
    transition: border-color 0.2s;
}

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

.form-group input::placeholder,
.form-group textarea::placeholder {
    color: var(--text-gray-500);
}

.form-group textarea {
    min-height: 100px;
    resize: vertical;
}

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

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

@media (max-width: 640px) {
    .form-row,
    .form-row.three-col {
        grid-template-columns: 1fr;
    }
}

/* Checkbox/Toggle */
.form-check {
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.form-check input[type="checkbox"] {
    width: 1rem;
    height: 1rem;
    accent-color: var(--brand-gold);
}

.form-check label {
    margin: 0;
    font-size: 0.875rem;
    color: var(--text-gray-300);
}

/* Modal */
.modal-overlay {
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.8);
    backdrop-filter: blur(4px);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 100;
    padding: 1rem;
}

.modal-overlay.hidden {
    display: none;
}

.modal {
    background: var(--brand-card);
    border-radius: 0.75rem;
    width: 100%;
    max-width: 600px;
    max-height: 90vh;
    overflow-y: auto;
}

.modal-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 1rem 1.5rem;
    border-bottom: 1px solid var(--brand-darker);
}

.modal-header h2 {
    font-size: 1.125rem;
    font-weight: 600;
    color: var(--text-white);
    margin: 0;
}

.modal-close {
    background: none;
    border: none;
    color: var(--text-gray-400);
    cursor: pointer;
    padding: 0.25rem;
    display: flex;
    align-items: center;
    justify-content: center;
}

.modal-close:hover {
    color: var(--text-white);
}

.modal-body {
    padding: 1.5rem;
}

.modal-footer {
    display: flex;
    justify-content: flex-end;
    gap: 0.75rem;
    padding: 1rem 1.5rem;
    border-top: 1px solid var(--brand-darker);
}

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

.stat-card {
    background: var(--brand-card);
    border-radius: 0.75rem;
    padding: 1.25rem;
}

.stat-card .stat-icon {
    width: 48px;
    height: 48px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 1rem;
    background: rgba(186, 155, 121, 0.2);
}

.stat-card .stat-icon svg {
    width: 24px;
    height: 24px;
    color: var(--brand-gold);
}

.stat-card .stat-value {
    font-size: 1.875rem;
    font-weight: 700;
    color: var(--text-white);
    margin-bottom: 0.25rem;
}

.stat-card .stat-label {
    font-size: 0.875rem;
    color: var(--text-gray-500);
}

/* Dashboard Grid */
.dashboard-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 1.5rem;
}

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

/* Reminders List (Dashboard) */
.reminders-list {
    display: flex;
    flex-direction: column;
}

.reminder-item {
    display: flex;
    align-items: center;
    gap: 1rem;
    padding: 1rem;
    border-bottom: 1px solid var(--brand-darker);
}

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

.reminder-icon {
    width: 40px;
    height: 40px;
    min-width: 40px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    background: rgba(186, 155, 121, 0.2);
    color: var(--brand-gold);
}

.reminder-icon svg {
    width: 20px;
    height: 20px;
}

.reminder-icon.birthday {
    background: rgba(168, 85, 247, 0.2);
    color: #a855f7;
}

.reminder-icon.vet {
    background: rgba(34, 197, 94, 0.2);
    color: #22c55e;
}

.reminder-icon.general {
    background: rgba(59, 130, 246, 0.2);
    color: #3b82f6;
}

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

.reminder-content h4 {
    font-size: 0.875rem;
    font-weight: 600;
    color: var(--text-white);
    margin: 0 0 0.25rem 0;
}

.reminder-content p {
    font-size: 0.75rem;
    color: var(--text-gray-400);
    margin: 0;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.reminder-date {
    font-size: 0.75rem;
    color: var(--text-gray-500);
    white-space: nowrap;
}

/* Tabs */
.tabs {
    display: flex;
    gap: 0.25rem;
    border-bottom: 1px solid var(--brand-darker);
    margin-bottom: 1.5rem;
}

.tab {
    padding: 0.75rem 1rem;
    font-size: 0.875rem;
    font-weight: 500;
    color: var(--text-gray-400);
    background: none;
    border: none;
    cursor: pointer;
    position: relative;
    transition: color 0.2s;
}

.tab:hover {
    color: var(--text-white);
}

.tab.active {
    color: var(--brand-gold);
}

.tab.active::after {
    content: '';
    position: absolute;
    bottom: -1px;
    left: 0;
    right: 0;
    height: 2px;
    background: var(--brand-gold);
}

/* Detail View */
.detail-header {
    display: flex;
    gap: 1.5rem;
    margin-bottom: 1.5rem;
    flex-wrap: wrap;
}

.detail-header .detail-image {
    width: 150px;
    height: 150px;
    border-radius: 0.75rem;
    object-fit: cover;
    background: var(--brand-darker);
    flex-shrink: 0;
}

.detail-header .detail-info {
    flex: 1;
}

.detail-header .detail-info h1 {
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--text-white);
    margin: 0 0 0.5rem;
}

.detail-header .detail-meta {
    display: flex;
    flex-wrap: wrap;
    gap: 1rem;
    color: var(--text-gray-400);
    font-size: 0.875rem;
}

.detail-header .detail-actions {
    display: flex;
    gap: 0.5rem;
    margin-top: 1rem;
}

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

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

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

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

@media (max-width: 640px) {
    .grid-2,
    .grid-3,
    .grid-4 {
        grid-template-columns: 1fr;
    }
}

/* Quick Actions */
.quick-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 0.75rem;
    margin-bottom: 1.5rem;
}

/* Activity List */
.activity-list {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.activity-item {
    display: flex;
    gap: 1rem;
    align-items: flex-start;
}

.activity-item .activity-icon {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}

.activity-item .activity-icon.green {
    background: rgba(34, 197, 94, 0.2);
    color: #4ade80;
}

.activity-item .activity-icon.blue {
    background: rgba(59, 130, 246, 0.2);
    color: #60a5fa;
}

.activity-item .activity-icon.purple {
    background: rgba(168, 85, 247, 0.2);
    color: #c084fc;
}

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

.activity-item .activity-title {
    color: var(--text-white);
    font-size: 0.875rem;
    margin-bottom: 0.125rem;
}

.activity-item .activity-subtitle {
    color: var(--text-gray-500);
    font-size: 0.875rem;
}

.activity-item .activity-time {
    color: var(--text-gray-600);
    font-size: 0.75rem;
}

/* Upcoming Events */
.event-list {
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
}

.event-item {
    display: flex;
    gap: 1rem;
    padding: 0.75rem;
    background: var(--brand-darker);
    border-radius: 0.5rem;
    align-items: center;
}

.event-item .event-date {
    text-align: center;
    min-width: 40px;
}

.event-item .event-date .day {
    font-size: 1.125rem;
    font-weight: 700;
    color: var(--brand-gold);
}

.event-item .event-date .month {
    font-size: 0.75rem;
    color: var(--text-gray-500);
}

.event-item .event-info .event-title {
    color: var(--text-white);
    font-size: 0.875rem;
}

.event-item .event-info .event-subtitle {
    color: var(--text-gray-500);
    font-size: 0.875rem;
}

/* Photo placeholder */
.photo-placeholder {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background: var(--brand-darker);
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--text-gray-500);
    font-size: 0.75rem;
    flex-shrink: 0;
}

/* Dashboard Notifications */
.dashboard-notifications {
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
    margin-bottom: 1.5rem;
}

.notification-item {
    display: flex;
    align-items: center;
    gap: 1rem;
    padding: 1rem;
    border-radius: 0.5rem;
    background: var(--brand-card);
}

.notification-item.notification-warning {
    border-left: 4px solid #f59e0b;
}

.notification-item.notification-danger {
    border-left: 4px solid #ef4444;
}

.notification-item.notification-info {
    border-left: 4px solid #3b82f6;
}

.notification-item.notification-success {
    border-left: 4px solid #22c55e;
}

.notification-icon {
    width: 40px;
    height: 40px;
    min-width: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.1);
}

.notification-icon svg {
    width: 20px;
    height: 20px;
}

.notification-warning .notification-icon {
    background: rgba(245, 158, 11, 0.2);
    color: #fbbf24;
}

.notification-danger .notification-icon {
    background: rgba(239, 68, 68, 0.2);
    color: #f87171;
}

.notification-info .notification-icon {
    background: rgba(59, 130, 246, 0.2);
    color: #60a5fa;
}

.notification-content {
    flex: 1;
}

.notification-content strong {
    display: block;
    color: var(--text-white);
    font-size: 0.875rem;
    margin-bottom: 0.125rem;
}

.notification-content p {
    margin: 0;
    color: var(--text-gray-400);
    font-size: 0.875rem;
}

.notification-action {
    flex-shrink: 0;
}

/* Button outline style */
.btn-outline {
    background: transparent;
    border: 1px solid var(--brand-card);
    color: var(--text-gray-300);
}

.btn-outline:hover {
    background: var(--brand-card);
    color: var(--text-white);
}

/* Utility classes */
.text-center {
    text-align: center;
}

.text-right {
    text-align: right;
}

.mt-4 {
    margin-top: 1rem;
}

.mb-4 {
    margin-bottom: 1rem;
}

/* Note: Don't define .hidden here - Tailwind provides it and we need responsive variants to work */

/* Modal Styles */
#modalOverlay {
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.2s ease;
}

#modalOverlay.active {
    opacity: 1;
    pointer-events: auto;
}

#modalOverlay.active #modal {
    transform: scale(1);
}

#modal {
    transform: scale(0.95);
    transition: transform 0.2s ease;
}

#modal.large {
    max-width: 800px;
}

#modalBody {
    max-height: 60vh;
}

/* Form styles inside modal */
#modalBody .form-group {
    margin-bottom: 1rem;
}

#modalBody label {
    display: block;
    font-size: 0.875rem;
    color: var(--text-gray-400);
    margin-bottom: 0.375rem;
}

#modalBody input,
#modalBody select,
#modalBody textarea {
    width: 100%;
    padding: 0.625rem 0.75rem;
    background: var(--brand-darker);
    border: 1px solid var(--brand-card);
    border-radius: 0.5rem;
    color: var(--text-white);
    font-size: 0.875rem;
}

#modalBody input:focus,
#modalBody select:focus,
#modalBody textarea:focus {
    outline: none;
    border-color: var(--brand-gold);
}

#modalBody textarea {
    min-height: 100px;
    resize: vertical;
}

#modalBody .form-row {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 1rem;
}

@media (max-width: 640px) {
    #modalBody .form-row {
        grid-template-columns: 1fr;
    }
}

/* Photo drop zone */
.photo-drop-zone {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    border: 2px dashed var(--brand-card);
    border-radius: 0.75rem;
    padding: 1.5rem;
    text-align: center;
    cursor: pointer;
    transition: border-color 0.2s, background-color 0.2s;
    background: var(--brand-darker);
    min-height: 120px;
}

.photo-drop-zone:hover,
.photo-drop-zone.drag-over,
.photo-drop-zone.dragover {
    border-color: var(--brand-gold);
    background: rgba(186, 155, 121, 0.08);
}

.photo-drop-zone .drop-icon {
    color: var(--text-gray-500);
    margin-bottom: 0.5rem;
    width: 40px;
    height: 40px;
}

.photo-drop-zone .drop-text {
    color: var(--text-gray-300);
    font-size: 0.875rem;
    font-weight: 500;
    margin: 0;
}

.photo-drop-zone .drop-hint {
    color: var(--text-gray-500);
    font-size: 0.75rem;
    margin: 0.25rem 0 0 0;
}

.photo-drop-zone img {
    max-width: 200px;
    max-height: 200px;
    object-fit: cover;
    border-radius: 0.5rem;
}

.photo-drop-zone p {
    color: var(--text-gray-500);
    font-size: 0.875rem;
    margin-top: 0.5rem;
}

/* ============================================
   Rabies Alert Styles
   ============================================ */
.rabies-alerts-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 1rem;
}

.rabies-alert-item {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 1rem;
    background: var(--bg-secondary);
    border-radius: 0.5rem;
    border-left: 3px solid var(--warning);
}

.rabies-alert-item.expired {
    border-left-color: var(--danger);
    background: rgba(244, 67, 54, 0.1);
}

.rabies-alert-item.no-record {
    border-left-color: var(--text-gray-500);
    background: rgba(107, 114, 128, 0.1);
}

.rabies-alert-item.expiring {
    border-left-color: var(--warning);
    background: rgba(255, 152, 0, 0.1);
}

.alert-dog-info {
    display: flex;
    align-items: center;
    gap: 0.75rem;
}

.alert-dog-photo,
.rabies-alert-item img,
.alert-dog-info img {
    width: 40px !important;
    height: 40px !important;
    min-width: 40px !important;
    max-width: 40px !important;
    min-height: 40px !important;
    max-height: 40px !important;
    border-radius: 50%;
    object-fit: cover;
    flex-shrink: 0;
}

.alert-dog-photo.placeholder {
    display: flex;
    align-items: center;
    justify-content: center;
    background: var(--brand-card);
    color: var(--text-gray-400);
    font-weight: 600;
    font-size: 1rem;
    width: 40px !important;
    height: 40px !important;
}

.alert-dog-info strong {
    display: block;
    color: var(--text-primary);
    font-size: 0.9rem;
}

.alert-status {
    display: block;
    font-size: 0.75rem;
    margin-top: 0.25rem;
}

.alert-status.expired {
    color: var(--danger);
}

.alert-status.expiring {
    color: var(--warning);
}

.alert-status.no-record {
    color: var(--text-gray-500);
}

/* ============================================
   Table Avatar/Name Styles
   ============================================ */
.table-name {
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.table-avatar {
    width: 32px !important;
    height: 32px !important;
    min-width: 32px !important;
    max-width: 32px !important;
    min-height: 32px !important;
    max-height: 32px !important;
    border-radius: 50%;
    object-fit: cover;
    flex-shrink: 0;
}

.table-avatar img,
.admin-table img {
    width: 32px !important;
    height: 32px !important;
    max-width: 32px !important;
    max-height: 32px !important;
    border-radius: 50%;
    object-fit: cover;
}

/* Constrain all images in admin tables */
.admin-table td img {
    width: 32px !important;
    height: 32px !important;
    max-width: 32px !important;
    max-height: 32px !important;
    border-radius: 50%;
    object-fit: cover;
}

/* ============================================
   Photo Preview Grid
   ============================================ */
.photo-preview-grid {
    display: flex;
    flex-wrap: wrap;
    gap: 0.75rem;
    margin-top: 1rem;
}

.photo-preview-grid:empty {
    display: none;
}

.photo-preview-item {
    position: relative;
    width: 90px;
    height: 90px;
    border-radius: 0.625rem;
    overflow: hidden;
    border: 2px solid var(--brand-card);
    background: var(--brand-darker);
    flex-shrink: 0;
}

.photo-preview-item.is-primary {
    border-color: var(--brand-gold);
    box-shadow: 0 0 0 2px rgba(186, 155, 121, 0.2);
}

.photo-preview-item img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.photo-preview-item.loading {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    background: var(--brand-card);
    gap: 0.25rem;
}

.photo-remove-btn {
    position: absolute;
    top: 4px;
    right: 4px;
    width: 22px;
    height: 22px;
    border-radius: 50%;
    background: rgba(0, 0, 0, 0.75);
    border: none;
    color: white;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    transition: opacity 0.2s, background 0.2s;
}

.photo-preview-item:hover .photo-remove-btn {
    opacity: 1;
}

.photo-remove-btn:hover {
    background: #dc2626;
}

/* Primary Photo Button (star) */
.photo-primary-btn {
    position: absolute;
    bottom: 4px;
    left: 4px;
    width: 24px;
    height: 24px;
    border-radius: 50%;
    background: rgba(0, 0, 0, 0.75);
    border: none;
    color: var(--text-gray-400);
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    transition: opacity 0.2s, color 0.2s, transform 0.2s;
}

.photo-preview-item:hover .photo-primary-btn {
    opacity: 1;
}

.photo-preview-item.is-primary .photo-primary-btn {
    opacity: 1;
    color: var(--brand-gold);
    background: rgba(0, 0, 0, 0.85);
}

.photo-primary-btn:hover {
    color: var(--brand-gold);
    transform: scale(1.1);
}

/* Upload Progress Indicator */
.upload-percent {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    background: rgba(0, 0, 0, 0.8);
    color: white;
    font-size: 0.65rem;
    text-align: center;
    padding: 2px 0;
}

.upload-spinner {
    width: 24px;
    height: 24px;
    border: 3px solid var(--brand-card);
    border-top-color: var(--brand-gold);
    border-radius: 50%;
    animation: spin 0.8s linear infinite;
}

/* Video Upload Styles */
.video-drop-zone {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 2rem;
    border: 2px dashed var(--brand-card);
    border-radius: 0.75rem;
    background: var(--brand-darker);
    cursor: pointer;
    transition: border-color 0.2s, background 0.2s;
}

.video-drop-zone:hover,
.video-drop-zone.drag-over {
    border-color: var(--brand-gold);
    background: rgba(186, 155, 121, 0.05);
}

.video-drop-zone .drop-icon {
    color: var(--text-gray-500);
    margin-bottom: 0.75rem;
}

.video-drop-zone .drop-text {
    color: var(--text-gray-300);
    font-weight: 500;
    margin: 0;
}

.video-drop-zone .drop-hint {
    color: var(--text-gray-500);
    font-size: 0.75rem;
    margin: 0.25rem 0 0 0;
}

.video-upload-progress {
    padding: 1.5rem;
    text-align: center;
}

.video-upload-progress .progress-bar {
    height: 8px;
    background: var(--brand-card);
    border-radius: 4px;
    overflow: hidden;
    margin-bottom: 0.5rem;
}

.video-upload-progress .progress-fill {
    height: 100%;
    background: var(--brand-gold);
    border-radius: 4px;
    transition: width 0.2s;
}

.video-upload-progress .progress-text {
    color: var(--text-gray-400);
    font-size: 0.875rem;
    margin: 0;
}

.video-preview {
    text-align: center;
}

.video-preview video {
    max-height: 300px;
    width: 100%;
    object-fit: contain;
}

/* Photo URL Input Toggle */
.photo-input-toggle {
    margin-top: 0.5rem;
}

.photo-input-toggle button {
    display: flex;
    align-items: center;
    gap: 0.25rem;
    color: var(--text-gray-500);
    font-size: 0.75rem;
    background: none;
    border: none;
    cursor: pointer;
    padding: 0;
}

.photo-input-toggle button:hover {
    color: var(--brand-gold);
}

.url-input-section {
    margin-top: 0.5rem;
}

.url-input-section.hidden {
    display: none;
}

.url-input-row {
    display: flex;
    gap: 0.5rem;
}

.url-input-row input {
    flex: 1;
}

/* ============================================
   Upload Progress & Spinner
   ============================================ */
.upload-spinner {
    width: 24px;
    height: 24px;
    border: 2px solid var(--brand-card);
    border-top-color: var(--brand-gold);
    border-radius: 50%;
    animation: spin 0.8s linear infinite;
}

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

.video-upload-progress {
    padding: 1.5rem;
    text-align: center;
}

.progress-bar {
    width: 100%;
    height: 8px;
    background: var(--brand-card);
    border-radius: 4px;
    overflow: hidden;
    margin-bottom: 0.75rem;
}

.progress-fill {
    height: 100%;
    background: var(--brand-gold);
    border-radius: 4px;
    transition: width 0.3s ease;
}

.progress-text {
    color: var(--text-gray-400);
    font-size: 0.875rem;
    margin: 0;
}

/* Video Drop Zone */
.video-drop-zone {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 2rem;
    border: 2px dashed var(--brand-card);
    border-radius: 0.5rem;
    cursor: pointer;
    transition: border-color 0.2s, background 0.2s;
}

.video-drop-zone:hover {
    border-color: var(--brand-gold);
    background: rgba(186, 155, 121, 0.1);
}

.video-drop-zone .drop-icon {
    color: var(--text-gray-500);
    margin-bottom: 0.75rem;
}

.video-drop-zone .drop-text {
    color: var(--text-gray-300);
    font-weight: 500;
    margin: 0 0 0.25rem 0;
}

.video-drop-zone .drop-hint {
    color: var(--text-gray-500);
    font-size: 0.75rem;
    margin: 0;
}

/* Video Preview */
.video-preview {
    text-align: center;
}

.video-preview video {
    max-width: 100%;
    border-radius: 0.5rem;
    background: var(--brand-darker);
}

/* ============================================
   REPORTS PAGE STYLES
   ============================================ */

/* Reports Grid Layout */
.reports-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 1.5rem;
    margin-top: 0;
}

@media (min-width: 768px) {
    .reports-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (min-width: 1280px) {
    .reports-grid {
        grid-template-columns: repeat(3, 1fr);
    }
}

/* Report Card */
.report-card {
    background: var(--brand-card);
    border-radius: 0.75rem;
    padding: 0;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.2);
    transition: transform 0.2s, box-shadow 0.2s;
    border: 1px solid rgba(255, 255, 255, 0.05);
}

.report-card:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.3);
    border-color: rgba(186, 155, 121, 0.3);
}

/* Bar Chart */
.bar-chart {
    display: flex;
    align-items: flex-end;
    justify-content: space-between;
    height: 220px;
    gap: 0.375rem;
    padding: 1.5rem 0.75rem 0.75rem;
    background: rgba(0, 0, 0, 0.2);
    border-radius: 0.5rem;
}

.bar-item {
    flex: 1;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.5rem;
    min-width: 0;
}

.bar-container {
    width: 100%;
    height: 160px;
    display: flex;
    align-items: flex-end;
    justify-content: center;
    position: relative;
}

.bar {
    width: 100%;
    max-width: 40px;
    background: linear-gradient(to top, rgba(186, 155, 121, 0.8), var(--brand-gold));
    border-radius: 4px 4px 0 0;
    transition: all 0.3s ease;
    cursor: pointer;
    position: relative;
    min-height: 2px;
    box-shadow: 0 -2px 8px rgba(186, 155, 121, 0.3);
}

.bar:hover {
    background: linear-gradient(to top, var(--brand-gold), var(--brand-gold-light));
    transform: scaleY(1.05) scaleX(1.1);
    box-shadow: 0 -4px 12px rgba(186, 155, 121, 0.5);
}

.bar::after {
    content: attr(title);
    position: absolute;
    bottom: 100%;
    left: 50%;
    transform: translateX(-50%);
    background: rgba(0, 0, 0, 0.95);
    color: var(--brand-gold-light);
    padding: 0.375rem 0.625rem;
    border-radius: 0.375rem;
    font-size: 0.75rem;
    font-weight: 600;
    white-space: nowrap;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.2s;
    margin-bottom: 0.5rem;
    border: 1px solid rgba(186, 155, 121, 0.3);
    z-index: 10;
}

.bar:hover::after {
    opacity: 1;
}

.bar-label {
    font-size: 0.7rem;
    color: var(--text-gray-400);
    font-weight: 600;
    text-align: center;
    text-transform: uppercase;
    letter-spacing: 0.025em;
}

/* Category Breakdown */
.category-breakdown {
    display: flex;
    flex-direction: column;
    gap: 1.25rem;
}

.category-item {
    display: grid;
    grid-template-columns: 160px 1fr 50px;
    align-items: center;
    gap: 1rem;
    padding: 0.75rem;
    background: rgba(0, 0, 0, 0.2);
    border-radius: 0.5rem;
    transition: background 0.2s;
}

.category-item:hover {
    background: rgba(0, 0, 0, 0.3);
}

.category-info {
    display: flex;
    flex-direction: column;
    gap: 0.25rem;
}

.category-name {
    font-size: 0.875rem;
    color: var(--text-gray-300);
    font-weight: 600;
}

.category-amount {
    font-size: 0.75rem;
    color: var(--brand-gold);
    font-weight: 600;
}

.category-bar {
    height: 10px;
    background: rgba(0, 0, 0, 0.3);
    border-radius: 5px;
    overflow: hidden;
    position: relative;
    box-shadow: inset 0 1px 3px rgba(0, 0, 0, 0.3);
}

.category-fill {
    height: 100%;
    background: linear-gradient(to right, rgba(186, 155, 121, 0.7), var(--brand-gold));
    border-radius: 5px;
    transition: width 0.6s ease;
    box-shadow: 0 0 8px rgba(186, 155, 121, 0.4);
}

.category-percent {
    font-size: 0.875rem;
    color: var(--brand-gold-light);
    font-weight: 700;
    text-align: right;
}

/* Puppy Stats Grid */
.puppy-stats-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 1rem;
}

@media (min-width: 640px) {
    .puppy-stats-grid {
        grid-template-columns: repeat(4, 1fr);
    }
}

.puppy-stat {
    text-align: center;
    padding: 1.25rem 0.75rem;
    background: rgba(0, 0, 0, 0.2);
    border-radius: 0.5rem;
    transition: all 0.2s;
}

.puppy-stat:hover {
    background: rgba(0, 0, 0, 0.3);
    transform: translateY(-2px);
}

.puppy-stat-value {
    display: block;
    font-size: 2.25rem;
    font-weight: 700;
    color: var(--brand-gold);
    margin-bottom: 0.5rem;
    line-height: 1;
}

.puppy-stat-label {
    display: block;
    font-size: 0.75rem;
    color: var(--text-gray-400);
    text-transform: uppercase;
    letter-spacing: 0.05em;
    font-weight: 600;
}

/* Breeding Stats */
.breeding-stats {
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
}

.breeding-stat-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 0.75rem 0;
    border-bottom: 1px solid var(--brand-darker);
}

.breeding-stat-row:last-child {
    border-bottom: none;
}

.breeding-stat-label {
    font-size: 0.875rem;
    color: var(--text-gray-400);
}

.breeding-stat-value {
    font-size: 1.25rem;
    font-weight: 600;
    color: var(--brand-gold);
}

/* Waitlist Stats */
.waitlist-stats {
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
}

.waitlist-stat-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 0.75rem 0;
    border-bottom: 1px solid var(--brand-darker);
}

.waitlist-stat-row:last-child {
    border-bottom: none;
}

.waitlist-stat-row span:first-child {
    font-size: 0.875rem;
    color: var(--text-gray-400);
}

.stat-badge {
    padding: 0.25rem 0.75rem;
    background: rgba(186, 155, 121, 0.2);
    color: var(--brand-gold);
    border-radius: 0.375rem;
    font-size: 0.875rem;
    font-weight: 600;
}

/* Profit Summary */
.profit-summary {
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
}

.profit-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 0.75rem 0;
    font-size: 0.875rem;
}

.profit-row span:first-child {
    color: var(--text-gray-400);
}

.profit-positive {
    color: #10b981;
    font-weight: 600;
    font-size: 1rem;
}

.profit-negative {
    color: #ef4444;
    font-weight: 600;
    font-size: 1rem;
}

.profit-total {
    border-top: 2px solid var(--brand-darker);
    padding-top: 1rem;
    margin-top: 0.5rem;
}

.profit-total span:first-child {
    font-weight: 600;
    color: var(--text-gray-300);
    font-size: 1rem;
}

.profit-total .profit-positive,
.profit-total .profit-negative {
    font-size: 1.5rem;
    font-weight: 700;
}

/* Stats Grid (for top-level metrics) */
.stats-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 1rem;
    margin-bottom: 2rem;
}

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

@media (min-width: 1024px) {
    .stats-grid {
        grid-template-columns: repeat(4, 1fr);
        gap: 1.5rem;
    }
}

.stat-card {
    background: var(--brand-card);
    border-radius: 0.75rem;
    padding: 1.5rem;
    display: flex;
    flex-direction: column;
    border: 1px solid rgba(255, 255, 255, 0.05);
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.2);
    transition: all 0.2s;
}

.stat-card:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.3);
    border-color: rgba(186, 155, 121, 0.2);
}

.stat-icon {
    width: 3.5rem;
    height: 3.5rem;
    border-radius: 0.75rem;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 1.25rem;
}

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

.stat-value {
    font-size: 2rem;
    font-weight: 700;
    color: var(--text-white);
    margin-bottom: 0.5rem;
    line-height: 1;
}

.stat-label {
    font-size: 0.875rem;
    color: var(--text-gray-400);
    font-weight: 500;
}

/* Color Variables for Stats */
:root {
    --success-color: #10b981;
    --success-bg: rgba(16, 185, 129, 0.1);
    --danger-color: #ef4444;
    --danger-bg: rgba(239, 68, 68, 0.1);
    --info-color: #3b82f6;
    --info-bg: rgba(59, 130, 246, 0.1);
    --warning-color: #f59e0b;
    --warning-bg: rgba(245, 158, 11, 0.1);
    --accent-gold: var(--brand-gold);
    --accent-gold-bg: rgba(186, 155, 121, 0.1);
    --text-muted: var(--text-gray-500);
    --text-primary: var(--text-white);
    --border-color: var(--brand-darker);
}

/* Admin Header for Reports Page */
.admin-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    margin-bottom: 2rem;
    flex-wrap: wrap;
    gap: 1rem;
}

.admin-header h1 {
    font-size: 1.875rem;
    font-weight: 700;
    color: var(--text-white);
    margin: 0 0 0.5rem 0;
}

.admin-subtitle {
    color: var(--text-gray-400);
    font-size: 0.875rem;
    margin: 0;
}

/* Admin Card (generic card for reports) */
.admin-card {
    background: var(--brand-card);
    border-radius: 0.75rem;
    overflow: hidden;
    height: 100%;
    display: flex;
    flex-direction: column;
}

.admin-card-header {
    padding: 1.25rem 1.5rem;
    border-bottom: 2px solid rgba(186, 155, 121, 0.2);
    background: rgba(0, 0, 0, 0.2);
}

.admin-card-header h2 {
    font-size: 1.125rem;
    font-weight: 700;
    color: var(--brand-gold-light);
    margin: 0;
    text-transform: uppercase;
    letter-spacing: 0.025em;
    font-size: 0.95rem;
}

.admin-card-body {
    padding: 1.5rem;
    flex: 1;
}

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

    .category-item {
        grid-template-columns: 1fr;
        gap: 0.75rem;
    }

    .category-percent {
        text-align: left;
    }

    .puppy-stats-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 0.75rem;
    }

    .bar-chart {
        height: 180px;
        padding: 1rem 0.5rem 0.5rem;
    }

    .bar-container {
        height: 130px;
    }

    .bar-label {
        font-size: 0.65rem;
    }
}

/* ============================================
   DOCUMENTS PAGE STYLES
   ============================================ */

.documents-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 1.5rem;
}

@media (min-width: 768px) {
    .documents-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (min-width: 1280px) {
    .documents-grid {
        grid-template-columns: repeat(3, 1fr);
    }
}

.document-card .admin-card-header h2 {
    display: flex;
    align-items: center;
    gap: 0.75rem;
}

.document-card .admin-card-header svg {
    color: var(--brand-gold);
}

.document-description {
    color: var(--text-gray-400);
    font-size: 0.875rem;
    line-height: 1.6;
    margin-bottom: 1.5rem;
    padding-bottom: 1.5rem;
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
}

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

.form-group label {
    display: block;
    font-size: 0.875rem;
    font-weight: 600;
    color: var(--text-gray-300);
    margin-bottom: 0.5rem;
}

.form-group input,
.form-group select,
.form-group textarea {
    width: 100%;
    padding: 0.75rem;
    background: rgba(0, 0, 0, 0.3);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 0.5rem;
    color: var(--text-white);
    font-size: 0.875rem;
    transition: all 0.2s;
}

.form-group input:focus,
.form-group select:focus,
.form-group textarea:focus {
    outline: none;
    border-color: var(--brand-gold);
    background: rgba(0, 0, 0, 0.4);
    box-shadow: 0 0 0 3px rgba(186, 155, 121, 0.1);
}

.form-group input::placeholder,
.form-group textarea::placeholder {
    color: var(--text-gray-500);
}

.form-row {
    display: grid;
    grid-template-columns: 1fr;
    gap: 1.25rem;
}

@media (min-width: 640px) {
    .form-row {
        grid-template-columns: repeat(2, 1fr);
    }
}

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

@media (min-width: 768px) {
    .form-row.three-col {
        grid-template-columns: repeat(3, 1fr);
    }
}

/* ============================================
   REMINDERS & BIRTHDAYS PAGE STYLES
   ============================================ */

.admin-tabs {
    display: flex;
    gap: 0.5rem;
    margin-bottom: 1.5rem;
    border-bottom: 2px solid rgba(255, 255, 255, 0.05);
}

.admin-tab,
.tab-btn {
    padding: 0.75rem 1.5rem;
    background: transparent;
    border: none;
    color: var(--text-gray-400);
    font-size: 0.875rem;
    font-weight: 600;
    cursor: pointer;
    border-bottom: 2px solid transparent;
    margin-bottom: -2px;
    transition: all 0.2s;
}

.admin-tab:hover,
.tab-btn:hover {
    color: var(--brand-gold-light);
}

.admin-tab.active,
.tab-btn.active {
    color: var(--brand-gold);
    border-bottom-color: var(--brand-gold);
}

.reminders-list {
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
}

.reminder-item {
    display: flex;
    align-items: center;
    gap: 1rem;
    padding: 1.25rem;
    background: var(--brand-card);
    border-radius: 0.75rem;
    border: 1px solid rgba(255, 255, 255, 0.05);
    transition: all 0.2s;
}

.reminder-item:hover {
    background: rgba(38, 38, 38, 0.8);
    border-color: rgba(186, 155, 121, 0.2);
    transform: translateX(4px);
}

.reminder-icon {
    width: 3rem;
    height: 3rem;
    border-radius: 0.75rem;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    background: rgba(186, 155, 121, 0.1);
}

.reminder-icon svg {
    color: var(--brand-gold);
}

.reminder-icon.vet {
    background: rgba(239, 68, 68, 0.1);
}

.reminder-icon.vet svg {
    color: var(--danger-color);
}

.reminder-icon.breeding {
    background: rgba(245, 158, 11, 0.1);
}

.reminder-icon.breeding svg {
    color: var(--warning-color);
}

.reminder-icon.birthday {
    background: rgba(59, 130, 246, 0.1);
}

.reminder-icon.birthday svg {
    color: var(--info-color);
}

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

.reminder-content h4 {
    font-size: 1rem;
    font-weight: 600;
    color: var(--text-white);
    margin: 0 0 0.25rem 0;
}

.reminder-content p {
    font-size: 0.875rem;
    color: var(--text-gray-400);
    margin: 0;
    overflow: hidden;
    text-overflow: ellipsis;
}

.reminder-date {
    padding: 0.375rem 0.75rem;
    background: rgba(0, 0, 0, 0.3);
    border-radius: 0.375rem;
    font-size: 0.8125rem;
    font-weight: 600;
    color: var(--brand-gold);
    white-space: nowrap;
}

.icon-btn {
    background: transparent;
    border: none;
    padding: 0.5rem;
    border-radius: 0.375rem;
    cursor: pointer;
    transition: all 0.2s;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--text-gray-400);
}

.icon-btn:hover {
    background: rgba(255, 255, 255, 0.05);
    color: var(--text-white);
}

.icon-btn.delete:hover {
    background: rgba(239, 68, 68, 0.1);
    color: var(--danger-color);
}

/* ============================================
   SITE SETTINGS & TABS
   ============================================ */

.tab-content {
    position: relative;
}

.tab-pane {
    display: none;
}

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

/* ============================================
   TABLE STYLES
   ============================================ */

.table-responsive {
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
}

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

.admin-table thead {
    background: rgba(0, 0, 0, 0.3);
}

.admin-table th {
    padding: 1rem;
    text-align: left;
    font-size: 0.75rem;
    font-weight: 700;
    color: var(--brand-gold-light);
    text-transform: uppercase;
    letter-spacing: 0.05em;
    border-bottom: 2px solid rgba(186, 155, 121, 0.2);
}

.admin-table td {
    padding: 1rem;
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
    font-size: 0.875rem;
    color: var(--text-gray-300);
}

.admin-table tbody tr {
    transition: background 0.2s;
}

.admin-table tbody tr:hover {
    background: rgba(0, 0, 0, 0.2);
}

.admin-table td strong {
    color: var(--text-white);
    font-weight: 600;
}

.status-badge {
    display: inline-block;
    padding: 0.25rem 0.75rem;
    border-radius: 0.375rem;
    font-size: 0.75rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.025em;
}

.status-badge.status-active {
    background: rgba(16, 185, 129, 0.1);
    color: var(--success-color);
}

.status-badge.status-pending {
    background: rgba(245, 158, 11, 0.1);
    color: var(--warning-color);
}

.action-buttons {
    display: flex;
    gap: 0.5rem;
    align-items: center;
}

.btn-icon {
    background: transparent;
    border: none;
    padding: 0.5rem;
    border-radius: 0.375rem;
    cursor: pointer;
    transition: all 0.2s;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--text-gray-400);
}

.btn-icon:hover {
    background: rgba(186, 155, 121, 0.1);
    color: var(--brand-gold);
}

.btn-icon-danger:hover {
    background: rgba(239, 68, 68, 0.1);
    color: var(--danger-color);
}

/* ============================================
   EMPTY STATES
   ============================================ */

.admin-empty-state {
    text-align: center;
    padding: 4rem 2rem;
}

.admin-empty-state svg {
    color: var(--text-gray-500);
    margin-bottom: 1rem;
    opacity: 0.5;
}

.admin-empty-state p {
    color: var(--text-gray-500);
    font-size: 1rem;
    margin: 0 0 1.5rem 0;
}

.no-padding {
    padding: 0 !important;
}

/* ============================================
   WAITLIST PAGE STYLES
   ============================================ */

.stat-info h3 {
    font-size: 1.875rem;
    font-weight: 700;
    color: var(--text-white);
    margin: 0 0 0.25rem 0;
    line-height: 1;
}

.stat-info p {
    font-size: 0.875rem;
    color: var(--text-gray-400);
    margin: 0;
}

.pending-deposits-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 1rem;
}

@media (min-width: 768px) {
    .pending-deposits-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (min-width: 1280px) {
    .pending-deposits-grid {
        grid-template-columns: repeat(3, 1fr);
    }
}

.deposit-card {
    padding: 1.25rem;
    background: rgba(0, 0, 0, 0.2);
    border-radius: 0.75rem;
    border: 1px solid rgba(255, 255, 255, 0.05);
    transition: all 0.2s;
}

.deposit-card:hover {
    background: rgba(0, 0, 0, 0.3);
    border-color: rgba(245, 158, 11, 0.3);
    transform: translateY(-2px);
}

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

.waitlist-table thead {
    background: rgba(0, 0, 0, 0.3);
}

.waitlist-table th {
    padding: 1rem;
    text-align: left;
    font-size: 0.75rem;
    font-weight: 700;
    color: var(--brand-gold-light);
    text-transform: uppercase;
    letter-spacing: 0.05em;
    border-bottom: 2px solid rgba(186, 155, 121, 0.2);
}

.waitlist-table td {
    padding: 1rem;
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
    font-size: 0.875rem;
    color: var(--text-gray-300);
}

.waitlist-table tbody tr {
    transition: background 0.2s;
}

.waitlist-table tbody tr:hover {
    background: rgba(0, 0, 0, 0.2);
}

/* Waitlist Position Badge */
.waitlist-position {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 2rem;
    height: 2rem;
    background: var(--brand-card, #262626);
    border: 2px solid var(--brand-gold, #ba9b79);
    border-radius: 50%;
    font-weight: 600;
    font-size: 0.875rem;
    color: var(--brand-gold, #ba9b79);
}

.waitlist-position.active {
    background: var(--brand-gold, #ba9b79);
    color: var(--brand-dark, #161616);
}

.waitlist-position-large {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 3.5rem;
    height: 3.5rem;
    background: var(--brand-gold, #ba9b79);
    color: var(--brand-dark, #161616);
    border-radius: 50%;
    font-weight: 700;
    font-size: 1.25rem;
}

/* Waitlist Status Badges */
.status-badge.status-active {
    background: rgba(76, 175, 80, 0.2);
    color: #4caf50;
}

.status-badge.status-pending {
    background: rgba(255, 152, 0, 0.2);
    color: #ff9800;
}

.status-badge.status-fulfilled {
    background: rgba(33, 150, 243, 0.2);
    color: #2196f3;
}

.status-badge.status-cancelled {
    background: rgba(158, 158, 158, 0.2);
    color: #9e9e9e;
}

/* Waitlist Table Row States */
.row-cancelled {
    opacity: 0.6;
    background: rgba(158, 158, 158, 0.05);
}

.row-fulfilled {
    background: rgba(33, 150, 243, 0.05);
}

/* Waitlist Detail Styles */
.waitlist-detail {
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
}

.waitlist-detail .detail-header {
    display: flex;
    align-items: center;
    gap: 1rem;
}

.waitlist-detail .detail-section {
    padding: 1rem;
    background: var(--brand-darker, #1e1e1e);
    border-radius: 0.5rem;
}

.waitlist-detail .detail-section h4 {
    margin-bottom: 1rem;
    font-size: 0.875rem;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    color: var(--brand-gold, #ba9b79);
}

.waitlist-detail .detail-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 1rem;
}

.waitlist-detail .detail-item label {
    display: block;
    font-size: 0.75rem;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    color: #9e9e9e;
    margin-bottom: 0.25rem;
}

.waitlist-detail .detail-item span {
    display: block;
    font-size: 0.9375rem;
}

/* Pending Deposits Card */
.pending-deposit-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 1rem;
    background: var(--brand-darker, #1e1e1e);
    border-radius: 0.5rem;
    gap: 1rem;
}

.pending-deposit-item .deposit-info {
    display: flex;
    flex-direction: column;
    gap: 0.25rem;
}

.pending-deposit-item .deposit-info strong {
    color: #fff;
}

.pending-deposit-item .deposit-info span {
    font-size: 0.875rem;
    color: #9e9e9e;
}

/* Form Checkbox Grid */
.checkbox-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
    gap: 0.5rem;
}

.checkbox-grid label {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    cursor: pointer;
    padding: 0.5rem;
    border-radius: 0.375rem;
    transition: background 0.2s;
}

.checkbox-grid label:hover {
    background: rgba(255, 255, 255, 0.05);
}

/* ============================================
   DOGS, LITTERS, PUPPIES, CUSTOMERS GRID STYLES
   ============================================ */

.dogs-grid,
.litters-grid,
.puppies-grid,
.customers-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 1.5rem;
}

@media (min-width: 640px) {
    .dogs-grid,
    .litters-grid,
    .puppies-grid,
    .customers-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (min-width: 1024px) {
    .dogs-grid,
    .litters-grid,
    .puppies-grid,
    .customers-grid {
        grid-template-columns: repeat(3, 1fr);
    }
}

@media (min-width: 1440px) {
    .dogs-grid {
        grid-template-columns: repeat(4, 1fr);
    }
}

.dog-card,
.litter-card,
.puppy-card,
.customer-card {
    background: var(--brand-card);
    border-radius: 0.75rem;
    overflow: hidden;
    border: 1px solid rgba(255, 255, 255, 0.05);
    transition: all 0.3s;
}

.dog-card:hover,
.litter-card:hover,
.puppy-card:hover,
.customer-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.3);
    border-color: rgba(186, 155, 121, 0.3);
}

.card-image {
    width: 100%;
    height: 240px;
    object-fit: cover;
    background: rgba(0, 0, 0, 0.3);
}

.card-content {
    padding: 1.25rem;
}

.card-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    margin-bottom: 0.75rem;
}

.card-title {
    font-size: 1.125rem;
    font-weight: 700;
    color: var(--text-white);
    margin: 0 0 0.25rem 0;
}

.card-subtitle {
    font-size: 0.875rem;
    color: var(--text-gray-400);
    margin: 0;
}

.card-info {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
    margin-top: 1rem;
    padding-top: 1rem;
    border-top: 1px solid rgba(255, 255, 255, 0.05);
}

.card-info-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-size: 0.875rem;
}

.card-info-label {
    color: var(--text-gray-500);
}

.card-info-value {
    color: var(--text-white);
    font-weight: 600;
}

.card-actions {
    display: flex;
    gap: 0.5rem;
    margin-top: 1rem;
    padding-top: 1rem;
    border-top: 1px solid rgba(255, 255, 255, 0.05);
}

.card-badge {
    display: inline-block;
    padding: 0.25rem 0.75rem;
    border-radius: 0.375rem;
    font-size: 0.75rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.025em;
}

.badge-available {
    background: rgba(16, 185, 129, 0.1);
    color: var(--success-color);
}

.badge-reserved {
    background: rgba(245, 158, 11, 0.1);
    color: var(--warning-color);
}

.badge-sold {
    background: rgba(59, 130, 246, 0.1);
    color: var(--info-color);
}

.badge-active {
    background: rgba(16, 185, 129, 0.1);
    color: var(--success-color);
}

.badge-retired {
    background: rgba(107, 114, 128, 0.1);
    color: var(--text-gray-500);
}

.badge-guardian {
    background: rgba(186, 155, 121, 0.1);
    color: var(--brand-gold);
}

/* ============================================
   EXPENSES & VET RECORDS PAGE STYLES
   ============================================ */

.expenses-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 1rem;
}

.expense-item,
.vet-record-item {
    display: grid;
    grid-template-columns: auto 1fr auto auto;
    align-items: center;
    gap: 1rem;
    padding: 1.25rem;
    background: var(--brand-card);
    border-radius: 0.75rem;
    border: 1px solid rgba(255, 255, 255, 0.05);
    transition: all 0.2s;
}

.expense-item:hover,
.vet-record-item:hover {
    background: rgba(38, 38, 38, 0.8);
    border-color: rgba(186, 155, 121, 0.2);
    transform: translateX(4px);
}

.expense-icon,
.vet-icon {
    width: 3rem;
    height: 3rem;
    border-radius: 0.75rem;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    background: rgba(186, 155, 121, 0.1);
}

.expense-icon svg,
.vet-icon svg {
    color: var(--brand-gold);
}

.expense-details,
.vet-details {
    min-width: 0;
}

.expense-title,
.vet-title {
    font-size: 1rem;
    font-weight: 600;
    color: var(--text-white);
    margin: 0 0 0.25rem 0;
}

.expense-meta,
.vet-meta {
    font-size: 0.875rem;
    color: var(--text-gray-400);
    margin: 0;
}

.expense-amount {
    font-size: 1.25rem;
    font-weight: 700;
    color: var(--brand-gold);
}

.expense-category {
    padding: 0.375rem 0.75rem;
    background: rgba(0, 0, 0, 0.3);
    border-radius: 0.375rem;
    font-size: 0.8125rem;
    font-weight: 600;
    color: var(--text-gray-400);
}

/* ============================================
   TESTIMONIALS & GALLERY PAGE STYLES
   ============================================ */

.testimonials-grid,
.gallery-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 1.5rem;
}

@media (min-width: 768px) {
    .testimonials-grid,
    .gallery-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (min-width: 1280px) {
    .testimonials-grid {
        grid-template-columns: repeat(3, 1fr);
    }

    .gallery-grid {
        grid-template-columns: repeat(4, 1fr);
    }
}

.testimonial-card {
    background: var(--brand-card);
    border-radius: 0.75rem;
    padding: 1.5rem;
    border: 1px solid rgba(255, 255, 255, 0.05);
    transition: all 0.3s;
    display: flex;
    flex-direction: column;
}

.testimonial-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.3);
    border-color: rgba(186, 155, 121, 0.3);
}

.testimonial-header {
    display: flex;
    align-items: center;
    gap: 1rem;
    margin-bottom: 1rem;
}

.testimonial-avatar {
    width: 3rem;
    height: 3rem;
    border-radius: 50%;
    background: rgba(186, 155, 121, 0.1);
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--brand-gold);
    font-weight: 700;
    font-size: 1.25rem;
}

.testimonial-author {
    flex: 1;
}

.testimonial-name {
    font-size: 1rem;
    font-weight: 600;
    color: var(--text-white);
    margin: 0 0 0.25rem 0;
}

.testimonial-rating {
    display: flex;
    gap: 0.25rem;
}

.testimonial-rating svg {
    color: #fbbf24;
}

.testimonial-content {
    flex: 1;
    font-size: 0.875rem;
    line-height: 1.6;
    color: var(--text-gray-300);
    margin-bottom: 1rem;
}

.testimonial-footer {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding-top: 1rem;
    border-top: 1px solid rgba(255, 255, 255, 0.05);
}

.gallery-item {
    background: var(--brand-card);
    border-radius: 0.75rem;
    overflow: hidden;
    border: 1px solid rgba(255, 255, 255, 0.05);
    transition: all 0.3s;
}

.gallery-item:hover {
    transform: translateY(-4px);
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.3);
    border-color: rgba(186, 155, 121, 0.3);
}

.gallery-image {
    width: 100%;
    height: 240px;
    object-fit: cover;
    background: rgba(0, 0, 0, 0.3);
}

.gallery-info {
    padding: 1rem;
}

.gallery-title {
    font-size: 1rem;
    font-weight: 600;
    color: var(--text-white);
    margin: 0 0 0.5rem 0;
}

.gallery-description {
    font-size: 0.875rem;
    color: var(--text-gray-400);
    margin: 0 0 1rem 0;
    overflow: hidden;
    text-overflow: ellipsis;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
}

/* ============================================
   FILTERS & SEARCH
   ============================================ */

.filters-bar {
    display: flex;
    flex-wrap: wrap;
    gap: 1rem;
    margin-bottom: 1.5rem;
    padding: 1.25rem;
    background: var(--brand-card);
    border-radius: 0.75rem;
    border: 1px solid rgba(255, 255, 255, 0.05);
}

.filter-group {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
    min-width: 200px;
    max-width: 250px;
}

.filter-label {
    font-size: 0.75rem;
    font-weight: 600;
    color: var(--text-gray-400);
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

.filter-select,
.filter-input,
.form-select {
    padding: 0.625rem 0.875rem;
    background: rgba(0, 0, 0, 0.3);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 0.5rem;
    color: var(--text-white);
    font-size: 0.875rem;
    transition: all 0.2s;
}

.filter-select:focus,
.filter-input:focus,
.form-select:focus {
    outline: none;
    border-color: var(--brand-gold);
    background: rgba(0, 0, 0, 0.4);
}

/* ============================================
   UTILITY CLASSES
   ============================================ */

.text-truncate {
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.line-clamp-2 {
    overflow: hidden;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
}

.line-clamp-3 {
    overflow: hidden;
    display: -webkit-box;
    -webkit-line-clamp: 3;
    -webkit-box-orient: vertical;
}

/* ============================================
   LOADING ANIMATIONS
   ============================================ */

@keyframes spin {
    0% {
        transform: rotate(0deg);
    }
    100% {
        transform: rotate(360deg);
    }
}

.photo-preview-item.loading {
    background: var(--brand-darker);
    display: flex;
    align-items: center;
    justify-content: center;
}

/* ============================================
   GUARDIAN APPLICATIONS & CONTACT MESSAGES
   ============================================ */

/* Status badges for applications */
.status-badge.status-contacted {
    background: rgba(59, 130, 246, 0.2);
    color: #3b82f6;
}

.status-badge.status-approved {
    background: rgba(34, 197, 94, 0.2);
    color: #22c55e;
}

.status-badge.status-rejected {
    background: rgba(239, 68, 68, 0.2);
    color: #ef4444;
}

/* Applicant and sender info cells */
.applicant-info,
.sender-info,
.contact-info,
.preferences-info {
    display: flex;
    flex-direction: column;
    gap: 0.25rem;
}

.applicant-info strong,
.sender-info strong {
    color: var(--text-white);
}

/* Message preview styling */
.message-preview {
    max-width: 250px;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    color: var(--text-gray-400);
}

/* Unread/Read indicators */
.unread-indicator,
.read-indicator {
    display: inline-block;
    width: 10px;
    height: 10px;
    border-radius: 50%;
}

.unread-indicator {
    background: var(--brand-gold, #ba9b79);
    box-shadow: 0 0 8px rgba(186, 155, 121, 0.5);
}

.read-indicator {
    background: var(--text-gray-500);
    opacity: 0.5;
}

/* Unread row styling */
.row-unread {
    background: rgba(186, 155, 121, 0.05);
}

.row-unread td {
    font-weight: 500;
}

/* Message detail styles */
.message-detail {
    padding: 1rem 0;
}

.message-meta {
    background: var(--brand-darker, #1e1e1e);
    padding: 1rem;
    border-radius: 0.5rem;
}

.meta-row {
    margin-bottom: 0.5rem;
}

.meta-row:last-child {
    margin-bottom: 0;
}

.meta-row strong {
    color: var(--text-gray-400);
    margin-right: 0.5rem;
}

.message-body {
    margin-top: 1rem;
    padding: 1rem;
    background: var(--brand-darker, #1e1e1e);
    border-radius: 0.5rem;
    line-height: 1.6;
}

/* Detail grid for applications */
.detail-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 1.5rem;
}

.detail-section {
    padding: 1rem;
    background: var(--brand-darker, #1e1e1e);
    border-radius: 0.5rem;
}

.detail-section.full-width {
    grid-column: span 2;
}

.detail-section h3 {
    font-size: 0.875rem;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    color: var(--brand-gold, #ba9b79);
    margin-bottom: 1rem;
}

.detail-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 0.5rem 0;
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
}

.detail-row:last-child {
    border-bottom: none;
}

.detail-label {
    color: var(--text-gray-400);
}

.detail-value {
    color: var(--text-white);
    font-weight: 500;
}

.detail-text {
    color: var(--text-gray-300);
    line-height: 1.6;
    white-space: pre-wrap;
}

/* Status options in modal */
.status-options {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.status-options .btn {
    justify-content: flex-start;
    padding: 0.75rem 1rem;
}

.status-options .btn.btn-active {
    background: rgba(186, 155, 121, 0.2);
    border-color: var(--brand-gold, #ba9b79);
}

/* Badge styling */
.badge {
    display: inline-block;
    padding: 0.25rem 0.5rem;
    border-radius: 0.25rem;
    font-size: 0.75rem;
    background: rgba(255, 255, 255, 0.1);
    color: var(--text-gray-300);
}

.badge-success {
    background: rgba(34, 197, 94, 0.2);
    color: #22c55e;
}

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

    .detail-section.full-width {
        grid-column: span 1;
    }

    .message-preview {
        max-width: 120px;
    }
}

/* ============================================
   MODERN CARD-BASED APPLICATIONS & MESSAGES
   ============================================ */

/* Applications Grid */
.applications-grid,
.messages-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(340px, 1fr));
    gap: 1.5rem;
    padding: 1.5rem;
}

/* Empty State */
.empty-state {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 4rem 2rem;
    text-align: center;
    color: var(--text-gray-400, #9ca3af);
}

.empty-state svg {
    color: var(--text-gray-500, #6b7280);
    margin-bottom: 1.5rem;
    opacity: 0.5;
}

.empty-state h3 {
    font-size: 1.125rem;
    font-weight: 600;
    color: var(--text-gray-300, #d1d5db);
    margin: 0 0 0.5rem;
}

.empty-state p {
    font-size: 0.875rem;
    color: var(--text-gray-500, #6b7280);
    margin: 0;
}

/* Application Card */
.application-card,
.message-card {
    background: var(--brand-darker, #1e1e1e);
    border-radius: 1rem;
    border: 1px solid rgba(255, 255, 255, 0.05);
    overflow: hidden;
    transition: all 0.3s ease;
}

.application-card:hover,
.message-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 12px 40px rgba(0, 0, 0, 0.4);
    border-color: rgba(186, 155, 121, 0.3);
}

.message-card {
    cursor: pointer;
}

.card-rejected {
    opacity: 0.6;
    border-left: 3px solid #ef4444;
}

.card-approved {
    border-left: 3px solid #22c55e;
}

.card-unread {
    border-left: 3px solid var(--brand-gold, #ba9b79);
    background: linear-gradient(135deg, rgba(186, 155, 121, 0.05) 0%, var(--brand-darker, #1e1e1e) 100%);
}

/* Card Header */
.application-card-header,
.message-card-header {
    display: flex;
    align-items: center;
    gap: 1rem;
    padding: 1.25rem 1.25rem 1rem;
}

.applicant-avatar,
.sender-avatar {
    width: 48px;
    height: 48px;
    min-width: 48px;
    border-radius: 50%;
    background: linear-gradient(135deg, var(--brand-gold, #ba9b79) 0%, #8b7355 100%);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.25rem;
    font-weight: 700;
    color: var(--brand-dark, #161616);
}

.avatar-unread {
    box-shadow: 0 0 0 3px rgba(186, 155, 121, 0.3);
}

.applicant-details,
.sender-details {
    flex: 1;
    min-width: 0;
}

.applicant-name,
.sender-name {
    font-size: 1rem;
    font-weight: 600;
    color: var(--text-white, #fff);
    margin: 0;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.applicant-location,
.sender-email {
    font-size: 0.813rem;
    color: var(--text-gray-400, #9ca3af);
    margin: 0.25rem 0 0;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.unread-dot {
    width: 10px;
    height: 10px;
    min-width: 10px;
    background: var(--brand-gold, #ba9b79);
    border-radius: 50%;
    box-shadow: 0 0 10px rgba(186, 155, 121, 0.5);
}

/* Card Body */
.application-card-body,
.message-card-body {
    padding: 0 1.25rem 1rem;
}

.info-row {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    margin-bottom: 0.5rem;
    color: var(--text-gray-400, #9ca3af);
}

.info-row svg {
    min-width: 16px;
    opacity: 0.6;
}

.info-link {
    color: var(--brand-gold, #ba9b79);
    text-decoration: none;
    font-size: 0.875rem;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

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

/* Application Tags */
.application-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
    margin-top: 1rem;
}

.app-tag {
    display: inline-flex;
    align-items: center;
    gap: 0.375rem;
    padding: 0.375rem 0.75rem;
    background: rgba(255, 255, 255, 0.08);
    border-radius: 2rem;
    font-size: 0.75rem;
    color: var(--text-gray-300, #d1d5db);
}

.app-tag svg {
    opacity: 0.7;
}

.app-tag.tag-success {
    background: rgba(34, 197, 94, 0.15);
    color: #22c55e;
}

/* Application Excerpt */
.application-excerpt,
.message-excerpt {
    margin-top: 1rem;
    padding: 0.875rem;
    background: rgba(255, 255, 255, 0.03);
    border-radius: 0.5rem;
    border-left: 2px solid var(--brand-gold, #ba9b79);
}

.application-excerpt p,
.message-excerpt {
    font-size: 0.875rem;
    color: var(--text-gray-400, #9ca3af);
    line-height: 1.5;
    margin: 0;
    font-style: italic;
}

/* Message specific styles */
.message-subject {
    font-size: 0.938rem;
    font-weight: 600;
    color: var(--text-white, #fff);
    margin: 0 0 0.5rem;
}

.message-excerpt {
    font-style: normal;
    border-left: none;
    background: none;
    padding: 0;
    margin: 0;
    display: -webkit-box;
    -webkit-line-clamp: 3;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

/* Card Footer */
.application-card-footer,
.message-card-footer {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 1rem 1.25rem;
    background: rgba(0, 0, 0, 0.2);
    border-top: 1px solid rgba(255, 255, 255, 0.05);
}

.submission-date,
.message-date {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-size: 0.813rem;
    color: var(--text-gray-500, #6b7280);
}

.submission-date svg,
.message-date svg {
    opacity: 0.6;
}

.card-actions {
    display: flex;
    gap: 0.5rem;
}

.btn-card-action {
    width: 36px;
    height: 36px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: rgba(255, 255, 255, 0.08);
    border: none;
    border-radius: 0.5rem;
    color: var(--text-gray-400, #9ca3af);
    cursor: pointer;
    transition: all 0.2s ease;
    text-decoration: none;
}

.btn-card-action:hover {
    background: rgba(255, 255, 255, 0.15);
    color: var(--text-white, #fff);
}

.btn-card-action.btn-reply:hover {
    background: rgba(186, 155, 121, 0.2);
    color: var(--brand-gold, #ba9b79);
}

.btn-card-action.btn-danger:hover {
    background: rgba(239, 68, 68, 0.2);
    color: #ef4444;
}

/* Mobile Responsive */
@media (max-width: 640px) {
    .applications-grid,
    .messages-grid {
        grid-template-columns: 1fr;
        padding: 1rem;
        gap: 1rem;
    }

    .applicant-avatar,
    .sender-avatar {
        width: 40px;
        height: 40px;
        min-width: 40px;
        font-size: 1rem;
    }

    .applicant-name,
    .sender-name {
        font-size: 0.938rem;
    }

    .application-card-header,
    .message-card-header {
        padding: 1rem;
    }

    .application-card-body,
    .message-card-body {
        padding: 0 1rem 1rem;
    }

    .application-card-footer,
    .message-card-footer {
        padding: 0.875rem 1rem;
        flex-wrap: wrap;
        gap: 0.75rem;
    }

    .card-actions {
        width: 100%;
        justify-content: flex-end;
    }

    .application-tags {
        gap: 0.375rem;
    }

    .app-tag {
        padding: 0.25rem 0.625rem;
        font-size: 0.688rem;
    }
}

/* ============================================
   LIST VIEW STYLES FOR APPLICATIONS & MESSAGES
   ============================================ */

.applications-list,
.messages-list {
    display: flex;
    flex-direction: column;
    gap: 1rem;
    padding: 1.5rem;
}

/* List Item Base */
.application-list-item,
.message-list-item {
    background: var(--brand-darker, #1e1e1e);
    border-radius: 0.75rem;
    border: 1px solid rgba(255, 255, 255, 0.05);
    overflow: hidden;
    transition: all 0.2s ease;
}

.application-list-item:hover,
.message-list-item:hover {
    border-color: rgba(186, 155, 121, 0.2);
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.2);
}

.item-rejected {
    opacity: 0.6;
    border-left: 3px solid #ef4444;
}

.item-approved {
    border-left: 3px solid #22c55e;
}

.item-unread {
    border-left: 3px solid var(--brand-gold, #ba9b79);
    background: linear-gradient(90deg, rgba(186, 155, 121, 0.05) 0%, var(--brand-darker, #1e1e1e) 100%);
}

/* List Header */
.application-list-header,
.message-list-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    padding: 1.25rem;
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
    gap: 1rem;
    flex-wrap: wrap;
}

.applicant-info-row,
.message-list-sender {
    display: flex;
    align-items: center;
    gap: 1rem;
    flex: 1;
    min-width: 0;
}

.sender-avatar-sm {
    width: 40px;
    height: 40px;
    min-width: 40px;
    border-radius: 50%;
    background: linear-gradient(135deg, var(--brand-gold, #ba9b79) 0%, #8b7355 100%);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1rem;
    font-weight: 700;
    color: var(--brand-dark, #161616);
}

.avatar-pending {
    box-shadow: 0 0 0 3px rgba(251, 191, 36, 0.3);
}

.applicant-main-info,
.sender-info-compact {
    flex: 1;
    min-width: 0;
}

.applicant-name-row,
.sender-name-row {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    flex-wrap: wrap;
    margin-bottom: 0.25rem;
}

.applicant-name,
.sender-name {
    font-size: 1rem;
    font-weight: 600;
    color: var(--text-white, #fff);
}

.unread-badge {
    display: inline-block;
    padding: 0.125rem 0.5rem;
    background: var(--brand-gold, #ba9b79);
    color: var(--brand-dark, #161616);
    font-size: 0.688rem;
    font-weight: 600;
    border-radius: 1rem;
    text-transform: uppercase;
}

.applicant-contact-row,
.sender-contact-row {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    flex-wrap: wrap;
}

.contact-link,
.sender-email-link,
.sender-phone-link {
    display: inline-flex;
    align-items: center;
    gap: 0.375rem;
    font-size: 0.813rem;
    color: var(--brand-gold, #ba9b79);
    text-decoration: none;
    transition: color 0.2s;
}

.contact-link:hover,
.sender-email-link:hover,
.sender-phone-link:hover {
    color: var(--brand-gold-light, #d2b491);
    text-decoration: underline;
}

.contact-link svg {
    opacity: 0.7;
}

.contact-divider {
    color: var(--text-gray-500, #6b7280);
    font-size: 0.75rem;
}

.no-phone-text {
    color: var(--text-gray-500, #6b7280);
    font-size: 0.75rem;
    font-style: italic;
    margin-left: 0.5rem;
}

/* Meta and Actions */
.application-meta,
.message-list-meta {
    display: flex;
    align-items: center;
    gap: 1rem;
    flex-shrink: 0;
}

.application-date,
.message-date-compact {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-size: 0.813rem;
    color: var(--text-gray-500, #6b7280);
}

.application-date svg,
.message-date-compact svg {
    opacity: 0.6;
}

.application-actions,
.message-actions {
    display: flex;
    gap: 0.5rem;
}

.btn-action-sm {
    display: inline-flex;
    align-items: center;
    gap: 0.375rem;
    padding: 0.5rem 0.75rem;
    background: rgba(255, 255, 255, 0.08);
    border: none;
    border-radius: 0.5rem;
    font-size: 0.75rem;
    color: var(--text-gray-300, #d1d5db);
    cursor: pointer;
    transition: all 0.2s ease;
    text-decoration: none;
}

.btn-action-sm:hover {
    background: rgba(255, 255, 255, 0.15);
    color: var(--text-white, #fff);
}

.btn-action-sm.btn-reply:hover {
    background: rgba(186, 155, 121, 0.2);
    color: var(--brand-gold, #ba9b79);
}

.btn-action-sm.btn-status:hover {
    background: rgba(59, 130, 246, 0.2);
    color: #3b82f6;
}

.btn-action-sm.btn-delete:hover {
    background: rgba(239, 68, 68, 0.2);
    color: #ef4444;
}

/* Application Details Grid */
.application-details-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
    gap: 1rem;
    padding: 1.25rem;
    background: rgba(0, 0, 0, 0.15);
}

.detail-box {
    display: flex;
    flex-direction: column;
    gap: 0.25rem;
}

.detail-box label {
    font-size: 0.688rem;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    color: var(--text-gray-500, #6b7280);
}

.detail-box p {
    font-size: 0.875rem;
    color: var(--text-white, #fff);
    margin: 0;
}

.detail-box p.text-success {
    color: #22c55e;
}

/* Application Reason */
.application-reason {
    padding: 1.25rem;
    border-top: 1px solid rgba(255, 255, 255, 0.05);
}

.application-reason label {
    display: block;
    font-size: 0.688rem;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    color: var(--text-gray-500, #6b7280);
    margin-bottom: 0.5rem;
}

.application-reason p {
    font-size: 0.875rem;
    color: var(--text-gray-300, #d1d5db);
    line-height: 1.6;
    margin: 0;
    white-space: pre-wrap;
}

/* Message List Content */
.message-list-content {
    padding: 1.25rem;
}

.message-subject-line {
    font-size: 1rem;
    font-weight: 600;
    color: var(--text-white, #fff);
    margin: 0 0 0.75rem;
}

.message-full-text {
    padding: 1rem;
    background: rgba(0, 0, 0, 0.15);
    border-radius: 0.5rem;
}

.message-full-text p {
    font-size: 0.875rem;
    color: var(--text-gray-300, #d1d5db);
    line-height: 1.7;
    margin: 0;
}

/* Mobile Responsive for List Views */
@media (max-width: 768px) {
    .applications-list,
    .messages-list {
        padding: 1rem;
        gap: 0.75rem;
    }

    .application-list-header,
    .message-list-header {
        flex-direction: column;
        padding: 1rem;
    }

    .applicant-info-row,
    .message-list-sender {
        width: 100%;
    }

    .application-meta,
    .message-list-meta {
        width: 100%;
        justify-content: space-between;
        padding-top: 0.75rem;
        border-top: 1px solid rgba(255, 255, 255, 0.05);
    }

    .application-details-grid {
        grid-template-columns: repeat(2, 1fr);
        padding: 1rem;
    }

    .application-reason,
    .message-list-content {
        padding: 1rem;
    }

    .btn-action-sm {
        padding: 0.5rem;
    }

    .btn-action-sm span,
    .btn-action-sm:not(.btn-delete):not(.btn-reply) {
        font-size: 0;
    }

    .btn-action-sm svg {
        margin: 0;
    }
}

@media (max-width: 480px) {
    .application-details-grid {
        grid-template-columns: 1fr;
    }

    .applicant-contact-row,
    .sender-contact-row {
        flex-direction: column;
        align-items: flex-start;
        gap: 0.25rem;
    }

    .contact-divider {
        display: none;
    }
}

/* ============================================
   MOBILE-FRIENDLY ADMIN DASHBOARD
   Comprehensive mobile improvements
   ============================================ */

/* --- Hamburger Menu Button in Header --- */
.mobile-menu-btn {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 44px;
    height: 44px;
    background: none;
    border: none;
    color: var(--brand-gold);
    cursor: pointer;
    border-radius: 0.5rem;
    transition: background 0.2s;
    -webkit-tap-highlight-color: transparent;
}

.mobile-menu-btn:hover,
.mobile-menu-btn:active {
    background: rgba(186, 155, 121, 0.15);
}

/* --- Sidebar Overlay --- */
.sidebar-overlay {
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.6);
    z-index: 40;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.3s ease;
    -webkit-backdrop-filter: blur(2px);
    backdrop-filter: blur(2px);
}

.sidebar-overlay.active {
    opacity: 1;
    pointer-events: auto;
}

/* --- Sidebar Drawer (Mobile) --- */
@media (max-width: 767px) {
    #sidebar {
        display: block !important;
        transform: translateX(-100%);
        transition: transform 0.3s ease;
        z-index: 45;
        width: 280px;
        max-width: 85vw;
    }

    #sidebar.mobile-open {
        transform: translateX(0);
    }

    /* Main content takes full width on mobile */
    #main-content {
        margin-left: 0 !important;
        padding: 1rem !important;
    }
}

/* --- Search Box Fix --- */
@media (max-width: 640px) {
    .search-box input {
        min-width: 0;
        width: 100%;
    }

    .admin-page-header {
        flex-direction: column;
        align-items: stretch;
    }

    .header-actions {
        width: 100%;
    }

    .header-actions .search-box {
        flex: 1;
    }

    .header-actions .search-box input {
        width: 100%;
    }
}

/* --- Touch-Friendly Buttons --- */
@media (max-width: 767px) {
    .btn,
    .btn-primary,
    .btn-secondary,
    .btn-danger,
    .btn-outline {
        min-height: 44px;
        padding: 0.625rem 1rem;
        font-size: 0.875rem;
    }

    .btn-sm {
        min-height: 38px;
        padding: 0.5rem 0.75rem;
    }

    .btn-icon,
    .icon-btn {
        min-width: 44px;
        min-height: 44px;
        padding: 0.625rem;
    }

    /* Quick action buttons */
    .quick-actions .btn,
    .flex.flex-wrap.gap-3 button {
        flex: 1 1 calc(50% - 0.375rem);
        min-height: 48px;
        justify-content: center;
    }

    /* Table action buttons */
    .admin-table .actions,
    .action-buttons {
        gap: 0.25rem;
    }

    .admin-table .actions .btn-icon,
    .action-buttons .btn-icon {
        min-width: 40px;
        min-height: 40px;
    }
}

/* --- Tables on Mobile --- */
@media (max-width: 767px) {
    .table-responsive {
        margin: 0 -1rem;
        padding: 0 0;
        border-radius: 0;
    }

    .admin-table th,
    .admin-table td {
        padding: 0.75rem 0.625rem;
        font-size: 0.8125rem;
    }

    .admin-table th {
        font-size: 0.6875rem;
    }

    /* Hide less-important columns on very small screens */
    .admin-table .hide-mobile {
        display: none;
    }

    /* Make table rows more readable */
    .admin-table .dog-cell,
    .admin-table .item-cell {
        gap: 0.5rem;
    }

    .admin-table .dog-cell img,
    .admin-table .item-cell img {
        width: 32px;
        height: 32px;
    }
}

/* --- Modals on Mobile --- */
@media (max-width: 767px) {
    #modalOverlay {
        align-items: flex-end;
        padding: 0;
    }

    #modal {
        max-width: 100%;
        margin: 0;
        border-radius: 1rem 1rem 0 0;
        max-height: 92vh;
    }

    #modal.large {
        max-width: 100%;
    }

    #modalBody {
        max-height: 70vh;
        padding: 1rem;
    }

    .modal-header,
    #modal > div:first-child {
        padding: 1rem;
    }

    .modal-footer,
    #modalFooter {
        padding: 1rem;
        flex-wrap: wrap;
    }

    .modal-footer .btn,
    #modalFooter .btn,
    #modalFooter button {
        flex: 1;
        min-height: 48px;
        justify-content: center;
    }

    /* Close button bigger tap target */
    #modal button[onclick="closeModal()"] {
        min-width: 44px;
        min-height: 44px;
        display: flex;
        align-items: center;
        justify-content: center;
    }

    /* CSS modal styles too */
    .modal {
        max-width: 100%;
        border-radius: 1rem 1rem 0 0;
        max-height: 92vh;
    }

    .modal-overlay {
        align-items: flex-end;
        padding: 0;
    }

    .modal-body {
        padding: 1rem;
    }

    .modal-footer {
        padding: 1rem;
    }
}

/* --- Forms on Mobile --- */
@media (max-width: 640px) {
    .form-group input,
    .form-group select,
    .form-group textarea,
    #modalBody input,
    #modalBody select,
    #modalBody textarea {
        font-size: 16px; /* Prevent iOS zoom on focus */
        padding: 0.75rem;
        min-height: 44px;
    }

    .form-group label,
    #modalBody label {
        font-size: 0.8125rem;
        margin-bottom: 0.5rem;
    }

    .form-check {
        min-height: 44px;
        padding: 0.25rem 0;
    }

    .form-check input[type="checkbox"] {
        width: 1.25rem;
        height: 1.25rem;
    }

    /* Photo drop zone adjustments */
    .photo-drop-zone {
        padding: 1.25rem 1rem;
        min-height: 100px;
    }

    .photo-preview-grid {
        gap: 0.5rem;
    }

    .photo-preview-item {
        width: 75px;
        height: 75px;
    }

    /* Photo remove button always visible on touch devices */
    .photo-preview-item .photo-remove-btn {
        opacity: 1;
        width: 28px;
        height: 28px;
    }

    .photo-preview-item .photo-primary-btn {
        opacity: 1;
        width: 28px;
        height: 28px;
    }
}

/* --- Stats Cards on Mobile --- */
@media (max-width: 640px) {
    .stats-grid {
        gap: 0.75rem;
    }

    .stat-card {
        padding: 1rem;
    }

    .stat-value {
        font-size: 1.5rem;
    }

    .stat-icon {
        width: 2.75rem;
        height: 2.75rem;
        margin-bottom: 0.75rem;
    }
}

/* --- Tabs on Mobile --- */
@media (max-width: 640px) {
    .tabs,
    .admin-tabs {
        overflow-x: auto;
        -webkit-overflow-scrolling: touch;
        scrollbar-width: none;
        flex-wrap: nowrap;
    }

    .tabs::-webkit-scrollbar,
    .admin-tabs::-webkit-scrollbar {
        display: none;
    }

    .tab,
    .admin-tab,
    .tab-btn {
        white-space: nowrap;
        padding: 0.625rem 0.875rem;
        font-size: 0.8125rem;
        min-height: 44px;
        flex-shrink: 0;
    }
}

/* --- Detail Views on Mobile --- */
@media (max-width: 640px) {
    .detail-header {
        flex-direction: column;
        align-items: center;
        text-align: center;
    }

    .detail-header .detail-image {
        width: 120px;
        height: 120px;
    }

    .detail-header .detail-info h1 {
        font-size: 1.25rem;
    }

    .detail-header .detail-meta {
        justify-content: center;
    }

    .detail-header .detail-actions {
        justify-content: center;
        flex-wrap: wrap;
    }

    .detail-header .detail-actions .btn {
        flex: 1;
        min-width: 120px;
    }
}

/* --- Notification Items on Mobile --- */
@media (max-width: 640px) {
    .notification-item {
        padding: 0.75rem;
    }

    .notification-action .btn {
        padding: 0.5rem 0.75rem;
        font-size: 0.75rem;
    }
}

/* --- Reminders on Mobile --- */
@media (max-width: 640px) {
    .reminder-item {
        flex-wrap: wrap;
        padding: 1rem;
    }

    .reminder-date {
        width: 100%;
        margin-top: 0.5rem;
        text-align: left;
    }
}

/* --- Applications/Messages Grid on Mobile --- */
@media (max-width: 640px) {
    .applications-grid,
    .messages-grid {
        grid-template-columns: 1fr;
        padding: 1rem;
        gap: 1rem;
    }
}

/* --- Category Breakdown on Mobile --- */
@media (max-width: 640px) {
    .category-item {
        grid-template-columns: 1fr 1fr;
    }

    .category-bar {
        grid-column: span 2;
    }
}

/* --- Dashboard Page Spacing on Mobile --- */
@media (max-width: 640px) {
    .mb-8 {
        margin-bottom: 1.5rem;
    }

    .gap-6 {
        gap: 1rem;
    }

    .p-6 {
        padding: 1rem;
    }
}

/* --- Login Modal on Mobile --- */
@media (max-width: 640px) {
    #loginModal > div {
        margin: 0 1rem;
        padding: 1.5rem;
    }

    #loginModal input {
        font-size: 16px; /* Prevent iOS zoom */
    }

    #loginModal button[type="submit"] {
        min-height: 48px;
    }
}

/* --- Safe Area Padding for Notched Phones --- */
@supports (padding: env(safe-area-inset-bottom)) {
    @media (max-width: 767px) {
        #modalFooter,
        .modal-footer {
            padding-bottom: calc(1rem + env(safe-area-inset-bottom));
        }

        #modal {
            padding-bottom: env(safe-area-inset-bottom);
        }
    }
}
