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

:root {
    --bg-color: #0d0d12;
    --card-bg: rgba(22, 22, 33, 0.6);
    --card-border: rgba(255, 255, 255, 0.08);
    --card-hover-border: rgba(111, 66, 193, 0.4);
    --primary-gradient: linear-gradient(135deg, #6366f1 0%, #a855f7 50%, #ec4899 100%);
    --primary-color: #a855f7;
    --text-primary: #f8fafc;
    --text-secondary: #94a3b8;
    --shadow-sm: 0 2px 8px rgba(0, 0, 0, 0.3);
    --shadow-lg: 0 10px 30px rgba(0, 0, 0, 0.5);
    --font-outfit: 'Outfit', sans-serif;
}

body {
    background-color: var(--bg-color);
    background-image: 
        radial-gradient(at 10% 20%, rgba(99, 102, 241, 0.15) 0px, transparent 50%),
        radial-gradient(at 90% 80%, rgba(236, 72, 153, 0.1) 0px, transparent 50%);
    background-attachment: fixed;
    color: var(--text-primary);
    font-family: var(--font-outfit);
    min-height: 100vh;
}

/* Glassmorphism Navigation Bar */
.ui.menu.custom-nav {
    background: rgba(22, 22, 33, 0.7) !important;
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    border: 1px solid var(--card-border) !important;
    box-shadow: var(--shadow-sm) !important;
    border-radius: 12px !important;
    margin-top: 1.5rem !important;
    margin-bottom: 2rem !important;
    padding: 0.2rem 1rem !important;
}

.ui.menu.custom-nav .item {
    color: var(--text-secondary) !important;
    font-family: var(--font-outfit);
    font-weight: 500;
    transition: all 0.3s ease;
    border-radius: 8px !important;
    margin: 0.2rem 0.1rem !important;
}

.ui.menu.custom-nav .item:hover {
    color: var(--text-primary) !important;
    background: rgba(255, 255, 255, 0.05) !important;
}

.ui.menu.custom-nav .item.active {
    background: var(--primary-gradient) !important;
    color: white !important;
    font-weight: 600;
    box-shadow: 0 4px 12px rgba(168, 85, 247, 0.3);
}

.ui.menu.custom-nav .header.item {
    font-size: 1.3rem;
    font-weight: 700;
    letter-spacing: -0.5px;
    background: var(--primary-gradient);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    padding-left: 0.5rem !important;
}

/* Container Tuning */
.main-container {
    max-width: 1000px !important;
    padding-bottom: 5rem;
}

/* Titles */
h1.ui.header, h2.ui.header, h3.ui.header {
    color: var(--text-primary) !important;
    font-family: var(--font-outfit) !important;
    font-weight: 700 !important;
}

.section-title {
    margin-bottom: 1.8rem !important;
    letter-spacing: -0.5px;
    position: relative;
    padding-left: 12px;
}

.section-title::before {
    content: '';
    position: absolute;
    left: 0;
    top: 15%;
    height: 70%;
    width: 4px;
    background: var(--primary-gradient);
    border-radius: 2px;
}

/* Glassmorphic Cards */
.custom-card {
    background: var(--card-bg) !important;
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
    border: 1px solid var(--card-border) !important;
    box-shadow: var(--shadow-sm) !important;
    border-radius: 16px !important;
    overflow: hidden;
    transition: all 0.4s cubic-bezier(0.16, 1, 0.3, 1) !important;
    display: flex;
    flex-direction: row;
    margin-bottom: 1.5rem;
    position: relative;
}

.custom-card:hover {
    transform: translateY(-4px);
    border-color: var(--card-hover-border) !important;
    box-shadow: var(--shadow-lg), 0 0 15px rgba(168, 85, 247, 0.15) !important;
}

.custom-card .card-image-container {
    position: relative;
    width: 160px;
    min-width: 160px;
    height: 240px;
    overflow: hidden;
}

.custom-card .card-image-container img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.5s ease;
}

.custom-card:hover .card-image-container img {
    transform: scale(1.05);
}

.custom-card .card-details {
    padding: 1.5rem;
    flex-grow: 1;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
}

.custom-card .card-title {
    font-size: 1.4rem;
    font-weight: 700;
    color: var(--text-primary);
    margin-bottom: 0.3rem;
    line-height: 1.2;
}

.custom-card .card-meta {
    font-size: 0.9rem;
    color: var(--text-secondary);
    margin-bottom: 0.8rem;
    display: flex;
    gap: 12px;
    align-items: center;
}

.custom-card .card-description {
    font-size: 0.95rem;
    line-height: 1.5;
    color: var(--text-secondary);
    display: -webkit-box;
    -webkit-line-clamp: 3;
    -webkit-box-orient: vertical;
    overflow: hidden;
    margin-bottom: 1rem;
}

/* Custom Badges */
.type-badge {
    padding: 0.2rem 0.6rem;
    border-radius: 6px;
    font-size: 0.75rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.type-badge.movie {
    background: rgba(99, 102, 241, 0.15);
    color: #818cf8;
    border: 1px solid rgba(99, 102, 241, 0.3);
}

.type-badge.tv {
    background: rgba(236, 72, 153, 0.15);
    color: #f472b6;
    border: 1px solid rgba(236, 72, 153, 0.3);
}

.rating-badge {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    background: rgba(251, 191, 36, 0.15);
    color: #fbbf24;
    border: 1px solid rgba(251, 191, 36, 0.3);
    padding: 0.2rem 0.6rem;
    border-radius: 6px;
    font-size: 0.85rem;
    font-weight: 600;
}

/* Action Controls */
.card-actions {
    display: flex;
    justify-content: space-between;
    align-items: center;
    border-top: 1px solid var(--card-border);
    padding-top: 1rem;
    margin-top: auto;
}

.action-buttons {
    display: flex;
    gap: 8px;
}

/* Styled Inputs & Forms */
.custom-search-container {
    background: var(--card-bg);
    border: 1px solid var(--card-border);
    border-radius: 16px;
    padding: 1.5rem;
    margin-bottom: 2rem;
    box-shadow: var(--shadow-sm);
}

.ui.input.custom-input input {
    background: rgba(0, 0, 0, 0.2) !important;
    border: 1px solid var(--card-border) !important;
    color: var(--text-primary) !important;
    border-radius: 10px !important;
    font-family: var(--font-outfit) !important;
    transition: border-color 0.3s ease !important;
}

.ui.input.custom-input input:focus {
    border-color: var(--primary-color) !important;
}

.ui.selection.dropdown.custom-dropdown {
    background: rgba(0, 0, 0, 0.2) !important;
    border: 1px solid var(--card-border) !important;
    color: var(--text-primary) !important;
    border-radius: 12px !important;
}

.ui.selection.dropdown.custom-dropdown .menu {
    background: #12121e !important;
    border: 1px solid var(--card-border) !important;
    border-radius: 12px !important;
    max-height: 200px;
    overflow-y: auto;
}

.ui.selection.dropdown.custom-dropdown .menu .item {
    color: var(--text-primary) !important;
}

.ui.selection.dropdown.custom-dropdown .menu .item[data-value=""] {
    color: var(--text-secondary) !important;
}

.custom-textarea {
    background: rgba(0, 0, 0, 0.2) !important;
    border: 1px solid var(--card-border) !important;
    color: var(--text-primary) !important;
    border-radius: 12px !important;
    font-family: var(--font-outfit) !important;
    padding: 1rem !important;
}

/* Premium Buttons */
.ui.button.premium-btn {
    background: var(--primary-gradient) !important;
    color: white !important;
    font-family: var(--font-outfit);
    font-weight: 600;
    border-radius: 10px !important;
    transition: all 0.3s ease;
    box-shadow: 0 4px 10px rgba(168, 85, 247, 0.2);
}

.ui.button.premium-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 14px rgba(168, 85, 247, 0.35);
    opacity: 0.95;
}

.ui.button.outline-btn {
    background: transparent !important;
    border: 1px solid var(--card-border) !important;
    color: var(--text-secondary) !important;
    font-family: var(--font-outfit);
    font-weight: 500;
    border-radius: 10px !important;
    transition: all 0.3s ease;
}

.ui.button.outline-btn:hover {
    color: var(--text-primary) !important;
    border-color: var(--text-secondary) !important;
    background: rgba(255, 255, 255, 0.03) !important;
}

.ui.button.danger-btn {
    background: rgba(239, 68, 68, 0.1) !important;
    border: 1px solid rgba(239, 68, 68, 0.2) !important;
    color: #ef4444 !important;
    font-family: var(--font-outfit);
    font-weight: 500;
    border-radius: 10px !important;
    transition: all 0.3s ease;
}

.ui.button.danger-btn:hover {
    background: rgba(239, 68, 68, 0.2) !important;
    color: #f87171 !important;
}

/* Queue Reordering Handles */
.drag-handle {
    display: flex;
    align-items: center;
    padding: 0 0.5rem;
    color: var(--text-secondary);
    cursor: grab;
}

.drag-handle:active {
    cursor: grabbing;
}

/* Modals */
.ui.modal.custom-modal {
    background: #12121e !important;
    border: 1px solid var(--card-border) !important;
    box-shadow: var(--shadow-lg) !important;
    border-radius: 16px !important;
}

.ui.modal.custom-modal .header {
    background: transparent !important;
    color: var(--text-primary) !important;
    border-bottom: 1px solid var(--card-border) !important;
    font-family: var(--font-outfit) !important;
}

.ui.modal.custom-modal .content {
    background: transparent !important;
    color: var(--text-secondary) !important;
}

.ui.modal.custom-modal .actions {
    background: transparent !important;
    border-top: 1px solid var(--card-border) !important;
}

/* Rating Stars */
.star-rating {
    display: flex;
    flex-direction: row-reverse;
    justify-content: flex-end;
    gap: 4px;
}

.star-rating input {
    display: none;
}

.star-rating label {
    font-size: 1.8rem;
    color: #334155;
    cursor: pointer;
    transition: color 0.2s ease;
}

.star-rating label::before {
    content: '★';
}

.star-rating input:checked ~ label,
.star-rating label:hover,
.star-rating label:hover ~ label {
    color: #fbbf24;
}

/* Personal Note Display */
.personal-review-box {
    background: rgba(168, 85, 247, 0.05);
    border-left: 3px solid var(--primary-color);
    padding: 1rem;
    border-radius: 0 10px 10px 0;
    margin-top: 0.8rem;
}

/* Toast Messages */
.ui.message.custom-flash {
    background: rgba(22, 22, 33, 0.8) !important;
    backdrop-filter: blur(10px);
    border: 1px solid var(--card-border) !important;
    color: var(--text-primary) !important;
    border-radius: 12px !important;
    box-shadow: var(--shadow-sm) !important;
}

.ui.message.custom-flash.success {
    border-left: 4px solid #10b981 !important;
}

.ui.message.custom-flash.error {
    border-left: 4px solid #ef4444 !important;
}

.ui.message.custom-flash.warning {
    border-left: 4px solid #f59e0b !important;
}

/* Streaming Badges & Logos */
.streaming-badge {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid var(--card-border);
    padding: 0.2rem;
    border-radius: 6px;
    vertical-align: middle;
    transition: all 0.3s ease;
}

.streaming-badge:hover {
    background: rgba(255, 255, 255, 0.1);
    border-color: rgba(255, 255, 255, 0.2);
    transform: scale(1.08);
}

.streaming-badge img {
    width: 18px;
    height: 18px;
    object-fit: contain;
    border-radius: 4px;
    display: block;
}

.streaming-logo-small {
    width: 20px;
    height: 20px;
    object-fit: contain;
    border-radius: 4px;
    display: inline-block;
    vertical-align: middle;
}

/* Season Cards & Details */
.season-card {
    transition: all 0.3s ease;
}

.season-card:hover {
    border-color: rgba(255, 255, 255, 0.15) !important;
    background: rgba(255, 255, 255, 0.02) !important;
}

.season-card.watched {
    background: rgba(16, 185, 129, 0.03) !important;
}

.season-card.watched:hover {
    border-color: rgba(16, 185, 129, 0.4) !important;
    background: rgba(16, 185, 129, 0.05) !important;
}

/* Season progress bar styling */
.ui.progress.success .bar {
    background: linear-gradient(90deg, #10b981, #059669) !important;
}

/* Mini star rating for seasons inside the modal */
.star-rating.mini label {
    font-size: 1.15rem;
    margin: 0 1px !important;
}

/* ==========================================================================
   Light Theme Style Tokens & Overrides
   ========================================================================== */
html[data-theme="light"] {
    --bg-color: #f1f5f9;
    --card-bg: rgba(255, 255, 255, 0.75);
    --card-border: rgba(15, 23, 42, 0.08);
    --card-hover-border: rgba(168, 85, 247, 0.5);
    --primary-gradient: linear-gradient(135deg, #4f46e5 0%, #8b5cf6 50%, #db2777 100%);
    --primary-color: #8b5cf6;
    --text-primary: #0f172a;
    --text-secondary: #475569;
    --shadow-sm: 0 2px 8px rgba(0, 0, 0, 0.05);
    --shadow-lg: 0 10px 30px rgba(0, 0, 0, 0.08);
}

/* Light Theme Radial Gradients */
html[data-theme="light"] body {
    background-image: 
        radial-gradient(at 10% 20%, rgba(99, 102, 241, 0.07) 0px, transparent 50%),
        radial-gradient(at 90% 80%, rgba(236, 72, 153, 0.05) 0px, transparent 50%);
}

/* Dropdown selections and lists in Light mode */
html[data-theme="light"] .ui.selection.dropdown .menu {
    background: #ffffff !important;
    border-color: rgba(15, 23, 42, 0.08) !important;
}

html[data-theme="light"] .ui.selection.dropdown .menu .item {
    color: #0f172a !important;
    border-top: 1px solid rgba(15, 23, 42, 0.05) !important;
}

html[data-theme="light"] .ui.selection.dropdown .menu .item:hover {
    background: #f1f5f9 !important;
}

html[data-theme="light"] input, 
html[data-theme="light"] textarea,
html[data-theme="light"] .ui.selection.dropdown {
    background: rgba(255, 255, 255, 0.9) !important;
    color: #0f172a !important;
    border-color: rgba(15, 23, 42, 0.15) !important;
}

/* Modals in Light mode */
html[data-theme="light"] .ui.modal.custom-modal {
    background: #ffffff !important;
    color: #0f172a !important;
    border: 1px solid rgba(0,0,0,0.1) !important;
    box-shadow: 0 15px 35px rgba(0,0,0,0.25) !important;
}

html[data-theme="light"] .ui.modal.custom-modal .header {
    background: #f8fafc !important;
    color: #0f172a !important;
    border-bottom-color: rgba(15, 23, 42, 0.08) !important;
}

html[data-theme="light"] .ui.modal.custom-modal .content {
    background: #ffffff !important;
    color: #0f172a !important;
}

html[data-theme="light"] .ui.modal.custom-modal .actions {
    background: #f8fafc !important;
    border-top-color: rgba(15, 23, 42, 0.08) !important;
}

html[data-theme="light"] .season-modal-item {
    border-bottom-color: rgba(15, 23, 42, 0.08) !important;
}

html[data-theme="light"] .season-modal-item select {
    background: #ffffff !important;
    color: #0f172a !important;
    border-color: rgba(15, 23, 42, 0.15) !important;
}

/* Star rating inactive state in Light mode */
html[data-theme="light"] .star-rating label {
    color: #cbd5e1;
}

html[data-theme="light"] .star-rating input:checked ~ label,
html[data-theme="light"] .star-rating label:hover,
html[data-theme="light"] .star-rating label:hover ~ label {
    color: #fbbf24;
}

/* Other slight light mode enhancements */
html[data-theme="light"] .ui.segment.details-card {
    background: rgba(255, 255, 255, 0.75) !important;
    border: 1px solid rgba(15, 23, 42, 0.08) !important;
}

html[data-theme="light"] .season-card {
    background: rgba(255, 255, 255, 0.5) !important;
}

html[data-theme="light"] .season-card.watched {
    background: rgba(16, 185, 129, 0.06) !important;
}

html[data-theme="light"] .personal-review-box {
    background: rgba(16, 185, 129, 0.04) !important;
}

html[data-theme="light"] .season-watch-form {
    background: rgba(0, 0, 0, 0.02) !important;
}

/* Custom Navigation Bar in Light mode */
html[data-theme="light"] .ui.menu.custom-nav {
    background: rgba(255, 255, 255, 0.7) !important;
    border-color: rgba(15, 23, 42, 0.08) !important;
}

html[data-theme="light"] .ui.menu.custom-nav .item:hover {
    background: rgba(0, 0, 0, 0.05) !important;
}

/* Custom Notifications / Flash Messages in Light mode */
html[data-theme="light"] .ui.message.custom-flash {
    background: rgba(255, 255, 255, 0.9) !important;
    border-color: rgba(15, 23, 42, 0.08) !important;
    color: #0f172a !important;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.05) !important;
}

html[data-theme="light"] .ui.message.custom-flash .header {
    color: #0f172a !important;
}

html[data-theme="light"] .ui.message.custom-flash p {
    color: #475569 !important;
}

html[data-theme="light"] .ui.message.custom-flash .close.icon {
    color: #64748b !important;
}

/* Custom Search Input in Light mode */
html[data-theme="light"] .ui.input.custom-input input {
    background: rgba(255, 255, 255, 0.95) !important;
    color: #0f172a !important;
    border-color: rgba(15, 23, 42, 0.15) !important;
}

html[data-theme="light"] .ui.input.custom-input input::placeholder {
    color: #94a3b8 !important;
}

html[data-theme="light"] .ui.input.custom-input input:focus {
    border-color: var(--primary-color) !important;
    background: #ffffff !important;
}

/* Form inputs & Labels in Light mode */
html[data-theme="light"] .ui.form input,
html[data-theme="light"] .ui.form textarea {
    background: rgba(255, 255, 255, 0.95) !important;
    color: #0f172a !important;
    border-color: rgba(15, 23, 42, 0.15) !important;
}

html[data-theme="light"] .ui.form .field > label {
    color: #0f172a !important;
}

/* Custom Dropdown and Textarea overrides in Light mode */
html[data-theme="light"] .ui.selection.dropdown.custom-dropdown {
    background: rgba(255, 255, 255, 0.95) !important;
    color: #0f172a !important;
    border-color: rgba(15, 23, 42, 0.15) !important;
}

html[data-theme="light"] .ui.selection.dropdown.custom-dropdown .menu {
    background: #ffffff !important;
    border-color: rgba(15, 23, 42, 0.15) !important;
}

html[data-theme="light"] .ui.selection.dropdown.custom-dropdown .menu .item {
    color: #0f172a !important;
    border-top: 1px solid rgba(15, 23, 42, 0.05) !important;
}

html[data-theme="light"] .ui.selection.dropdown.custom-dropdown .menu .item:hover {
    background: #f1f5f9 !important;
}

html[data-theme="light"] .custom-textarea {
    background: rgba(255, 255, 255, 0.95) !important;
    color: #0f172a !important;
    border-color: rgba(15, 23, 42, 0.15) !important;
}

/* ==========================================================================
   Responsive & Mobile Enhancements
   ========================================================================== */

/* Mobile Navigation Bar adjustments */
.toggle-menu-btn {
    display: none !important;
}

.menu-items-group {
    display: flex;
    flex-direction: row;
    align-items: center;
}

@media (max-width: 768px) {
    .ui.menu.custom-nav {
        display: flex !important;
        flex-direction: row !important;
        flex-wrap: wrap !important;
        align-items: center !important;
        justify-content: space-between !important;
        padding: 0.6rem 1.2rem !important;
        min-height: auto !important;
    }
    
    .ui.menu.custom-nav .header.item {
        padding: 0 !important;
        margin: 0 !important;
        background: transparent !important;
        box-shadow: none !important;
        display: flex !important;
        align-items: center !important;
    }
    
    .ui.menu.custom-nav .right.menu.mobile-controls {
        display: flex !important;
        flex-direction: row !important;
        align-items: center !important;
        margin-left: auto !important;
        padding: 0 !important;
        background: transparent !important;
        box-shadow: none !important;
    }
    
    .ui.menu.custom-nav .item:before {
        display: none !important;
    }
    
    .toggle-menu-btn {
        display: flex !important;
        padding: 0.5rem !important;
        margin-left: 0.8rem !important;
        color: var(--text-primary) !important;
        font-size: 1.3rem !important;
        background: transparent !important;
        box-shadow: none !important;
    }
    
    #theme-toggle {
        padding: 0.5rem !important;
        color: var(--text-primary) !important;
        font-size: 1.3rem !important;
        background: transparent !important;
        box-shadow: none !important;
        margin: 0 !important;
    }
    
    .menu-items-group {
        display: none;
        width: 100%;
        flex-direction: column;
        align-items: stretch;
        order: 10;
        margin-top: 0.8rem;
        border-top: 1px solid var(--card-border);
        padding-top: 0.5rem;
    }
    
    .menu-items-group.active {
        display: flex;
    }
    
    .menu-items-group .item {
        display: flex !important;
        align-items: center !important;
        width: 100% !important;
        padding: 0.8rem 1rem !important;
        margin: 0.2rem 0 !important;
        border-radius: 8px !important;
        color: var(--text-secondary) !important;
        font-size: 1rem !important;
        background: transparent !important;
        box-shadow: none !important;
        border: none !important;
    }
    
    .menu-items-group .item.active {
        background: var(--primary-gradient) !important;
        color: white !important;
    }
    
    .mobile-align-left {
        text-align: left !important;
        margin-top: 0.5rem !important;
    }
}

/* Custom Card mobile optimization */
@media (max-width: 600px) {
    /* Hide button labels on mobile — only icons show */
    .mobile-hide {
        display: none !important;
    }

    /* Keep card as a horizontal flex row — poster stays beside details */
    .custom-card {
        display: flex !important;
        flex-direction: row !important;
        flex-wrap: nowrap !important;
        align-items: stretch !important;
        padding: 10px !important;
        gap: 10px !important;
    }

    /* Shrink poster */
    .custom-card .card-image-container {
        width: 72px !important;
        min-width: 72px !important;
        height: 108px !important;
        align-self: flex-start !important;
        flex-shrink: 0 !important;
        border-radius: 6px !important;
    }

    /* Details take remaining space */
    .custom-card .card-details {
        flex: 1 !important;
        min-width: 0 !important;
        padding: 0 !important;
        display: flex !important;
        flex-direction: column !important;
        justify-content: space-between !important;
    }

    /* Smaller title */
    .custom-card .card-title {
        font-size: 0.95rem !important;
        white-space: nowrap !important;
        overflow: hidden !important;
        text-overflow: ellipsis !important;
    }

    /* Compact meta row */
    .custom-card .card-meta {
        font-size: 0.75rem !important;
        flex-wrap: wrap !important;
        gap: 4px !important;
        margin-bottom: 0.3rem !important;
    }

    /* Hide description */
    .custom-card .card-description {
        display: none !important;
    }

    /* Actions row: horizontal, compact, flush to bottom */
    .custom-card .card-actions {
        flex-direction: row !important;
        flex-wrap: wrap !important;
        gap: 4px !important;
        padding: 6px 0 0 !important;
        margin-top: auto !important;
        width: 100% !important;
        border-top: none !important;
        background: transparent !important;
    }

    /* Each action-buttons group is inline */
    .custom-card .card-actions > div,
    .custom-card .action-buttons {
        display: flex !important;
        flex-direction: row !important;
        flex-wrap: wrap !important;
        gap: 4px !important;
        width: auto !important;
    }

    /* Hide spacer empty divs */
    .custom-card .card-actions > div:first-child:empty {
        display: none !important;
    }

    /* All buttons become small square icon buttons */
    .custom-card .card-actions .button,
    .custom-card .card-actions a.button {
        padding: 0.4rem 0.55rem !important;
        font-size: 0.8rem !important;
        min-width: 32px !important;
        border-radius: 8px !important;
        flex: none !important;
        width: auto !important;
        display: inline-flex !important;
        align-items: center !important;
        justify-content: center !important;
        margin: 0 !important;
    }

    /* Forms inside actions stay inline */
    .custom-card .card-actions form {
        display: inline-flex !important;
        margin: 0 !important;
    }

    /* .ui.buttons wrapper goes horizontal */
    .custom-card .card-actions .ui.buttons {
        display: inline-flex !important;
        flex-direction: row !important;
        gap: 4px !important;
        width: auto !important;
    }

    .custom-card .card-actions .ui.buttons .button {
        border-radius: 8px !important;
    }

    /* Drag handle stays compact */
    .custom-card .drag-handle {
        padding: 0 4px 0 0 !important;
        align-self: flex-start !important;
        margin-top: 4px !important;
    }
}

/* Stacking search layout on small screens */
@media (max-width: 480px) {
    .ui.action.input.custom-input {
        flex-direction: column !important;
        gap: 8px !important;
    }
    
    .ui.action.input.custom-input input {
        border-radius: 10px !important;
        border-right-width: 1px !important;
        width: 100% !important;
    }
    
    .ui.action.input.custom-input .button {
        width: 100% !important;
        border-radius: 10px !important;
        margin: 0 !important;
    }
}

/* Stacking season cards layout on small screens */
@media (max-width: 480px) {
    .season-card {
        flex-direction: column !important;
        gap: 1rem !important;
        align-items: center !important;
        text-align: center !important;
        padding: 1.2rem !important;
    }
    
    .season-card .card-meta {
        justify-content: center !important;
        flex-wrap: wrap !important;
    }
}

