body {
    color: white;
    text-align: center;
    font-family: Arial, sans-serif;
    margin: 0;
    animation: fadeIn .15s ease-in;}

h1 {
    font-family: 'Poppins', sans-serif;
    color: #FFD700;
    text-shadow: 2px 2px 4px rgba(0,0,0,.35);
    font-size: 30px;
    margin-bottom: 15px;}

button {
    display: block;
    font-weight: 900;
    width: 190px;
    margin: 8px auto;
    padding: 12px;
    font-size: 18px;
    border: none;
    border-radius: 12px;
    box-shadow: 0 6px 14px rgba(0,0,0,.30);
    color: white;
    transition: transform .15s ease, box-shadow .15s ease, background-color .15s ease;
    border: 1px solid rgba(255,255,255,.25);}

.container {
    width: 95%;
    margin: auto;
    padding-top: 20px;}

.stats {
    max-width: 295px;
    width: 90%;
    margin: 20px auto;
    background-color: rgba(255,255,255,.15);
    padding: 12px;
    border-radius: 14px;
    position: relative;
    box-shadow: 0 6px 14px rgba(0,0,0,.25);}

a {text-decoration: none;}

button:hover {transform: translateY(-2px); box-shadow: 0 10px 20px rgba(0,0,0,.35);}

button:active {transform:translateY(2px) scale(0.97);}

.board-card {
    background-color: white;
    color: black;
    width: 250px;
    margin: 10px auto;
    padding: 20px;
    border-radius: 10px;
    font-size: 28px;
    font-weight: bold;}

.spot-row {
    display: flex;
    justify-content: center;
    gap: 10px;
    margin-bottom: 10px;}

.spot-label {
    width: 100px;
    background-color: gold;
    color: black;
    padding: 10px;
    border-radius: 5px;
    font-weight: bold;}



#schoolName {margin-right: 150px;}


.tag {
    width: 50px;
    background-color: white;
    color: black;
    padding: 10px;
    border-radius: 5px;
    font-weight: bold;}

.alert {background-color: #FFD700;}

.recent-card {
    background-color: rgba(255,255,255,.15);
    padding: 0px 20px 20px 20px;
    border-radius: 10px;
    margin-bottom: 20px;
    min-height: 350px;
    max-height: 60vh;
    overflow-y: auto;
    position: relative;}

input {
    width: 250px;
    padding: 18px;
    margin: 15px 0;
    border-radius: 12px;
    border: none;
    font-size: 28px;
    font-weight: bold;
    text-align: center;}

.release-card {
    background-color: rgba(255,255,255,.15);
    padding: 30px;
    border-radius: 10px;
    margin-top: 20px;
    margin-bottom: 20px;}

.release-card h2 {color: #FFD700; margin-bottom: 15px;}

.release-card p {font-size: 20px; font-weight: bold;}

.queue-item {
    background-color: rgba(255,255,255,.15);
    padding: 8px 12px;
    border-radius: 8px;
    margin-bottom: 6px;
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    min-height: 40px;}

.queue-item > span {
    display: flex;
    align-items: flex-start;
    flex-wrap: wrap;}    

.queue-item span {font-size: 18px; font-weight: bold;}

.queue-actions {display: flex; gap: 3px;}

.queue-actions button {
    transition: transform .1s ease, box-shadow .1s ease;
    width: 28px;
    height: 28px;
    padding: 0;
    margin: 0;}

.release-tag {
    width: 70px;
    background-color: white;
    color: black;
    padding: 10px;
    border-radius: 5px;
    font-weight: bold;
    cursor: pointer;
    text-align: center;}

.release-tag:hover {background-color: #FFD700;}

.released {background-color: #4CAF50; color: white;}

#dismissalBoard {
    display: grid;
    gap: 8px;
    width: 95vw;
    margin: 10px auto;}

.page-board h1 {
    margin-top: 5px;
    margin-bottom: 15px;
    font-size: 24px;}    

.board-tile {
    background-color: white;
    color: black;
    border-radius: 12px;
    display: flex;
    position: relative;
    white-space: normal;
    flex-wrap: wrap;
    justify-content: center;
    align-items: center;
    align-content: center;
    text-align: center;
    font-weight: bold;
    aspect-ratio: 2 / 1;}

.board-large {
    font-size: clamp(2rem, 4vw, 4.5rem); color: black;}

.board-tile.board-large {
    color: black !important;
}    

.spot-header {
    background-color: gold;
    color: black;
    font-weight: bold;
    padding: 10px;
    border-radius: 5px;}

.release-cell {
    transition: transform .1s ease, box-shadow .1s ease, background-color .15s ease;
    background-color: white;
    color: black;
    font-size: 22px;
    font-weight: bold;
    padding: 10px;
    border-radius: 5px;
    cursor: pointer;
    text-align: center;
    white-space: normal;
    min-width: 120px;
    min-height: 42px;
    display: flex;
    position: relative;
    flex-wrap: wrap;
    justify-content: center;
    align-items: center;
    align-content: center;
    word-break: break-word;}

.release-cell:active {transform: translateY(2px) scale(0.97);}

.release-cell.released {background-color: #4CAF50; color: white;}

.empty-cell {
    background-color: rgba(255,255,255,.03);
    border: 1px solid rgba(255,255,255,.05);
    cursor: default;}

.release-board-wrapper {
    overflow-x: auto;
    overflow-y: visible;
    width: 100%;
    margin-top: 20px;
    padding-bottom: 10px;
    min-height: calc(100vh - 230px);}

.page-release .release-board-wrapper {min-height: calc(100vh - 160px);}    

#releaseBoard,
#spotManagerBoard {
    display: grid;
    gap: 6px;
    margin-bottom: 10px;
    width: max-content;}

.spot-cell {
    position: sticky;
    left: 0;
    z-index: 10;
    background-color: #21478F;
    color: white;
    font-weight: 700;
    font-size: 20px;
    border-radius: 5px;
    display: flex;
    justify-content: center;
    align-items: center;
    min-height: 42px;
    padding: 10px;
    white-space: nowrap;
}

.needs-student {background-color: #FFD700; color: black;}

.board-alert { background-color: #FFD700; color: black;}

.history-card {
    background-color: white;
    color: black;
    border-radius: 12px;
    padding: 15px;
    position: relative;
    margin-bottom: 15px;
    text-align: left;
    box-shadow: 0 4px 10px rgba(0,0,0,.2);}

.history-card p {color: #666; margin: 3px 0;}

.history-card strong {color: black;}

.history-card h2 {
    display: inline-block;
    background-color: #F4F4F4;
    padding: 4px 12px;
    border-radius: 8px;
    font-family: 'Poppins', sans-serif;
    font-size: 32px;
    margin: 0;}

.history-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    width: 100%;
    margin-bottom: 12px;
    padding-bottom: 10px;
    border-bottom: 1px solid rgba(0,0,0,.15);}

.history-actions {
    position: absolute;
    top: 15px;
    right: 15px;
    display: flex;
    gap: 8px;}

.edit-history {
    transition: transform .1s ease, box-shadow .1s ease, background-color .15s ease;
    width: 40px;
    height: 40px;
    display: flex;
    justify-content: center;
    align-items: center;
    padding: 0;
    margin: 0;
    border: none;
    border-radius: 8px;
    background-color: #4A7DFF;
    color: white;
    cursor: pointer;
    box-shadow: 0 3px 8px rgba(0,0,0,.25);}

.edit-history:hover {background-color: #2554C7;}

.edit-history:active {transform: translateY(2px) scale(0.95);}

.edit-history i {pointer-events: none;}

.delete-history {
    transition: transform .1s ease, box-shadow .1s ease, background-color .15s ease;
    width: 40px;
    height: 40px;
    display: flex;
    justify-content: center;
    align-items: center;
    padding: 0;
    margin: 0;
    border: none;
    border-radius: 8px;
    background-color: #DC3545;
    color: white;
    cursor: pointer;
    box-shadow: 0 3px 8px rgba(0,0,0,.25);}

.delete-history:active {transform: translateY(2px) scale(0.95);}

.delete-history:hover {
    background-color: #C82333;
    transform: translateY(-1px);}

.delete-history i {pointer-events: none;}

h3 {
    margin-top: -2px;
    margin-bottom: 15px;
    color: rgba(255,255,255,.9);
    font-weight: normal;
    min-height: 28px;}

.helper-text {
    font-size: 14px;
    opacity: 0.8;
    margin-top: -7px;
    margin-bottom: 15;}

.current-stats {
    text-align: center;
    width: fit-content;
    margin: 0 auto;}

.current-stats p {
    margin: 3px 0;
    font-weight: 700;
    font-size: 18px;}

.page-home {background:linear-gradient(180deg,#4C00B0,#2E006D); min-height: 100vh;}

.page-car {background: linear-gradient(180deg,#5B9CFF,#326BFF); min-height: 100vh;}

.page-release {background:linear-gradient(180deg,#244B74,#102A43); min-height: 100vh;}

.page-board {background:linear-gradient(180deg,#21478F,#142D60); min-height: 100vh;}

.page-spot {background: linear-gradient(180deg,#9A50FF,#6A00F4); min-height: 100vh;}

.page-history {background: linear-gradient(180deg,#C08300,#8B5E00); min-height: 100vh;}

.page-settings {background:linear-gradient(180deg,#8F99A8,#667085); min-height: 100vh;}

.settings-card {
    width: 100%;
    height: auto;
    max-width: 650px;
    margin: 20px auto;
    padding: 20px;
    background-color: rgba(255,255,255,.15);
    border-radius: 15px;
    border: 1px solid rgba(255,255,255,.08);
    box-shadow: 0 8px 20px rgba(0,0,0,.25);
    box-sizing: border-box;}

.settings-card h2 {
    color: #222;
    font-size: 22px;
    font-weight: 700;
    text-align: left;
    border-bottom: 1px solid rgba(255,255,255,.15);
    padding-bottom: 10px;
    margin-bottom: 14px;}
    
.settings-row {
    display: flex;
    align-items: center;
    justify-content: flex-start;
    gap: 30px;
    margin-bottom: 18px;}

.settings-row label {
    width: 250px;
    text-align: left;
    font-size: 18px;
    font-weight: 600;
    padding-left: 15px;}

.settings-row input {
    width: 290px;
    font-size: 18px;
    padding: 10px;
    margin: 0;}

.settings-row input[type="checkbox"] {transform: scale(1.5);}

.btn-save-settings {
    margin-top: 30px;
    background-color: #4A7DFF;
    color: white;
    width: 220px;
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 8px;}

.stats h2 {margin: 0 0 10px 0; color: #FFD700;}

.board-empty {
    background-color:rgba(255,255,255,.05);
    border: 1px solid rgba(255,255,255,.08);
    box-shadow: none;
    aspect-ratio: 2 / 1;}

.queue-actions button:first-child {
    background-color: #4A7DFF;
    color: white;}

.queue-actions button:last-child {
    background-color: #DC3545;
    color: white;}

.queue-actions button:active {transform:translateY(2px) scale(0.95);}

.queue-actions button:disabled {opacity: .4; cursor: default;}

.pending-tag {opacity: .4;}

@keyframes fadeIn {
    from {opacity: 0;}
    to {opacity: 1;}}

.entry-card h2,
.recent-card h2 {
    margin-top: 0;
    margin-bottom: 0;
    font-size: 20px;
    font-weight: 700;
    letter-spacing: .3px;}

.recent-card h2 {
    position: sticky;
    top: 0;
    z-index: 20;
    margin: 0 -20px;
    margin-bottom: 8px;
    padding: 14px 0;
    background: linear-gradient(180deg,rgb(134,176,250),rgb(108,157,245));
    border-top-left-radius: 10px;
    border-top-right-radius: 10px;
    box-shadow:
        0 2px 8px rgba(0,0,0,.15);}

.queue-position {
    display: inline-block;
    width: 24px;
    font-weight: bold;
    opacity: .45;}

.duplicate-tag {
    display: inline-block;
    background-color: white;
    color: black;
    padding: 3px 10px;
    border-radius: 8px;
    font-weight: bold;
    margin-right: 4px;
    border: 2px solid #f5b400;
    box-shadow: 0 2px 4px rgba(0,0,0,.15);}

.queue-tag {
    display: inline-block;
    background-color: white;
    color: black;
    padding: 3px 10px;
    border-radius: 8px;
    font-weight: bold;
    margin-right: 4px;
    box-shadow: 0 2px 4px rgba(0,0,0,.15);}

.released-tag {background-color: #4CAF50; color: white;}

.alert-tag {background-color: #FFD700; color: black;}

.empty-queue {
    display: flex;
    justify-content: center;
    align-items: center;
    height: 250px;
    opacity: .6;
    font-style: italic;}

.queue-status {
    display: inline-flex;
    width: 24px;
    justify-content: center;
    align-items: center;
    margin-right: 4px;
    font-size: 16px;}

.status-saving {color: #FFD700;}

.status-saving i {animation: spin .8s linear infinite; display: inline-block;}

.status-saved {color: #4CAF50;}

.status-failed {color: #FF4D4D;}

@keyframes spin {
    from {transform: rotate(0deg);}
    to {transform: rotate(360deg);}}

.connection-status {
    position: fixed;
    top: 15px;
    right: 15px;
    font-size: 13px;
    font-weight: 600;
    opacity: .65;
    z-index: 900;}

.connection-online {color: #7dff7d;}

.connection-syncing {color: #FFD54F;}    

.connection-offline {color: #ff7b7b;}

.fullscreen-btn {
    position: absolute;
    top: 15px;
    right: 15px;
    width: 50px;
    height: 50px;
    margin: 0;
    padding: 0;
    display: flex;
    justify-content: center;
    align-items: center;
    border-radius: 50%;
    border: none;
    background-color: #4A7DFF;
    color: white;
    font-size: 22px;
    cursor: pointer;
    z-index: 999;
    box-shadow: 0 4px 10px rgba(0,0,0,.25);
    transition: transform .1s ease, box-shadow .15s ease, background-color .15s ease;}

.fullscreen-btn:active {transform: translateY(2px) scale(0.95);}

.fullscreen-btn i,
.home-icon i,
.trash-page-icon i,
.logout-icon i {line-height: 1; pointer-events: none;}

.home-icon,
.trash-page-icon,
.logout-icon {
    position: absolute;
    top: 15px;
    width: 50px;
    height: 50px;
    display: flex;
    justify-content: center;
    align-items: center;
    border-radius: 50%;
    color: white;
    text-decoration: none;
    box-shadow: 0 4px 10px rgba(0,0,0,.25);
    z-index: 999;
    font-size: 22px;
    transition: transform .1s ease, box-shadow .15s ease, background-color .15s ease;}

.logout-icon {
    right: 15px;
    width: 50px;
    height: 50px;
    padding: 0;
    margin: 0;
    background-color: #6C757D;}

.logout-icon:hover {background-color: #5A6268;}

.latest-history {border: 2px solid #FFD700;}   
    
.latest-badge {
    background-color: #FFD700;
    color: black;
    font-size: 12px;
    font-weight: 700;
    padding: 4px 8px;
    border-radius: 6px;}

.history-edited {
    text-align: right;
    font-size: 12px;
    opacity: .55;
    margin-top: 12px;
    font-style: italic;}   

.history-date-group {
    display: flex;
    align-items: center;}

.fastest-badge {
    background-color: #28A745;
    color: white;
    padding: 4px 8px;
    border-radius: 6px;
    font-size: 12px;
    font-weight: 700;}

.busiest-badge {
    background-color: #4A7DFF;
    color: white;
    padding: 4px 8px;
    border-radius: 6px;
    font-size: 12px;
    font-weight: 700;} 
      
.weather-toggle {
    position: absolute;
    top: 0px;
    right: 8px;
    width: 28px;
    height: 28px;
    display: flex;
    justify-content: center;
    align-items: center;
    border: none;
    border-radius: 50%;
    font-size: 18px;
    cursor: pointer;
    transition: transform .1s ease, background-color .15s ease;
    box-shadow: 0 3px 8px rgba(0,0,0,.25);}

.weather-toggle:hover {background-color: rgba(255,255,255,.25);}

.weather-toggle:active {transform:translateY(2px) scale(.95);}   

.weather-toggle i {pointer-events: none;}

.weather-toggle.rain {background-color: #5DADE2; color: white;}

.weather-toggle.sun {background-color: #795106; color: rgb(255, 218, 95);}   
    
.rain-badge {
    background-color: #5DADE2;
    color: white;
    padding: 4px 8px;
    border-radius: 6px;
    font-size: 12px;
    font-weight: 700;}  

.spot-alert-age {
    position: absolute;
    bottom: 5px;
    right: 8px;
    font-size: 10px;
    opacity: .85;
    pointer-events: none;}

.history-badges {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-top: 10px;
    margin-bottom: 10px;}
    
.board-spot {
    position: absolute;
    top: 6px;
    right: 8px;
    font-size: 14px;
    font-weight: 800;
    opacity: 1;
}

.board-tile.spot-red {background: #f04040;}
.board-tile.spot-orange {background: #eea861;}
.board-tile.spot-yellow {background: #ffeb85;}
.board-tile.spot-green {background: #339142;}
.board-tile.spot-blue {background: #5a8fdf;}
.board-tile.spot-purple {background: #b291f0;}
.board-tile.spot-pink {background: #f0a8ce;}
.board-tile.spot-teal {background: #70f7e2;}
.board-tile.spot-brown {background: #b4723c;}
.board-tile.spot-gray {background: #aeb7c2;}



.edited-badge {
    background-color: #6c757d;
    color: white;
    padding: 4px 8px;
    border-radius: 6px;
    font-size: 12px;
    font-weight: 700;}    

.btn-end:disabled {opacity: .7; cursor: default;}

.settings-helper {
    font-size: 13px;
    margin-top: 20px;
    margin-bottom: 18px;
    margin-left: 15px;
    padding-left: 15px;
    text-align: left;
    max-width: 400px;
    border-left: 2px solid rgba(255,255,255,.2);}

#startSpot,
#endSpot,
#carsDisplayed {width: 60px; max-width: 60px;}

.switch {
    position: relative;
    display: inline-block;
    width: 36px;
    height: 20px;}

.slider:before {
    position: absolute;
    content: "";
    height: 14px;
    width: 14px;
    left: 3px;
    bottom: 3px;
    background-color: white;
    transition: .2s;
    border-radius: 50%;}

.switch input:checked + .slider:before {transform: translateX(16px);}

.switch input {opacity: 0; width: 0; height: 0;}

.slider {
    position: absolute;
    cursor: pointer;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-color: #777;
    transition: .2s;
    border-radius: 22px;}

.switch input:checked + .slider {background-color: #4A7DFF;}

.settings-toggle-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 4px;}

.settings-toggle-row label:first-child {
    width: auto;
    font-size: 18px;
    font-weight: 600;
    padding-left: 15px;}

.settings-helper-tight {margin-top: -20px;}

.admin-buttons {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 12px;
    width: fit-content;
    max-width: 320px;
    margin: 10px auto 20px auto;}

.btn-admin {
    width: 100px !important;
    height: 70px;
    display: flex !important;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    gap: 4px;
    padding: 0;
    margin: 0;
    font-size: 13px;
    font-weight: 700;}

.btn-admin i {font-size: 24px;}

.btn-launcher {
    width: 100%;
    height: 100px;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    gap: 8px;
    padding: 0;
    font-size: 14px;
    font-weight: 700;}

.launcher-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 12px;
    max-width: 320px;
    margin: 0 auto 15px auto;}

.btn-car {background: linear-gradient(180deg,#7AB0FF,#5A96F2);}

.btn-release {background: linear-gradient(180deg,#7CE6D6,#57C9B7);}

.btn-board {background: linear-gradient(180deg,#4F7EFF,#3559C7);}

.btn-spot {background: linear-gradient(180deg,#C29BFF,#9D6BEB);}

.btn-history-admin { background: linear-gradient(180deg,#FFE07A,#FFD54F); color: #222;}

.btn-history-admin:hover {background: linear-gradient(180deg,#FFE899,#FFD54F);}

.btn-settings-admin:hover {background: linear-gradient(180deg,#8A97A5,#6C7A89);}

.btn-end-admin:hover {background: linear-gradient(180deg,#FF9A94,#E45D55);}

.btn-settings-admin {background: linear-gradient(180deg,#7D8B99,#5E6B77); color: white;}

.btn-end-admin {background: linear-gradient(180deg,#FF8A82,#E45D55); color: white;}
  
.btn-launcher,
.btn-admin {
    border: 1px solid rgba(255,255,255,.15);
    box-shadow:0 10px 24px rgba(0,0,0,.35);
    position: relative;
    overflow: hidden;
    transition: transform .15s ease, box-shadow .15s ease, filter .15s ease;}

.btn-launcher::before,
.btn-admin::before {
    content: "";
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 35%;
    background: linear-gradient(rgba(255,255,255,.18),rgba(255,255,255,0));
    pointer-events: none;}

.btn-launcher:hover,
.btn-admin:hover {
    transform: translateY(-3px);
    box-shadow: 0 10px 22px rgba(0,0,0,.35);
    filter: brightness(1.05);}

.btn-launcher i {font-size: 48px;}

body::before {
    content: "";
    position: fixed;
    width: 500px;
    height: 500px;
    border-radius: 50%;
    background: rgba(255,255,255,.03);
    top: -200px;
    right: -100px;
    pointer-events: none;
    z-index: -1;}

body::after {
    content: "";
    position: fixed;
    width: 400px;
    height: 400px;
    background: rgba(255,255,255,.02);
    transform: rotate(35deg);
    bottom: -150px;
    left: -100px;
    pointer-events: none;
    z-index: -1;}

@media (max-width: 600px) {
    h1 {font-size: 30px;}
    .home-icon,
    .fullscreen-btn,
    .trash-page-icon,
    .logout-icon {
        width: 40px;
        height: 40px;
        font-size: 18px;
        top: 10px;}
    .home-icon {left: 10px;}

.fullscreen-btn,
.trash-page-icon,
.logout-icon {right: 10px;}

    .release-cell {
        font-size: 16px;
        min-height: 28px;
        padding: 4px;}

    .spot-cell {
        width: 42px;
        min-width: 42px;
        min-height: 42px;
        padding: 12px;
        font-size: 20px;}

    .spot-range-row {flex-direction: row; gap: 24px;}
    
    .settings-row {
        flex-direction: column;
        align-items: stretch;
        gap: 8px;}

    .settings-row label {
        width: 100%;
        color: white;
        font-weight: 700;
        text-align: left;}

    .settings-row input {
        width: 250px;
        max-width: 100%;
        margin: 0 auto;}

    .history-time-row {flex-direction: column; gap: 0; }

    input {
        width: 100%;
        max-width: 280px;
        font-size: 28px;
        font-weight: bold;
        padding: 14px;}

    .queue-tag,
    .duplicate-tag {padding: 2px 8px; font-size: 16px;}}
               
.btn-end-admin .fa-arrows-rotate {animation: spin .8s linear infinite;}   
    
.btn-locate-student {
    width: 220px;
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 10px;
    margin: 10px auto 20px auto;
    background: linear-gradient(180deg, #FFD54F, #E6B93C);
    color: #333;}

.btn-locate-student i {font-size: 18px;}

.deleted-actions {
    display: flex;
    gap: 10px;
    margin-top: 15px;}

.restore-history-btn {
    background-color: #28A745;
    color: white;
    width: 140px;}

.delete-forever-btn {
    background-color: #DC3545;
    color: white;
    width: 170px;}

.home-icon:hover,
.trash-page-icon:hover,
.fullscreen-btn:hover,
.logout-icon:hover {
    color: white;
    transform: translateY(-2px);
    box-shadow: 0 6px 14px rgba(0,0,0,.35);}

.home-icon {left: 15px; background-color: #4A7DFF;}

.trash-page-icon {right: 15px; background-color: #7952B3;}

.home-icon:hover {background-color: #2554C7;}

.trash-page-icon:hover {background-color: #6841A1;}

.home-icon:active,
.trash-page-icon:active,
.logout-icon:active {
    transform: translateY(2px) scale(.95);}

.app-modal {
    position: fixed;
    inset: 0;
    background: rgba(0,0,0,.45);
    backdrop-filter: blur(2px);
    display: flex;
    justify-content: center;
    align-items: flex-start;
    padding-top: 18vh;
    overflow-y: auto;
    z-index: 5000;}

.hidden {display: none;}

.app-modal-content {
    width: 90%;
    max-width: 340px;
    animation: modalPop .15s ease;   
    background: white;
    color: black;
    border-radius: 16px;
    padding: 20px;
    box-shadow:
        0 15px 40px rgba(0,0,0,.35);}

.app-modal-content h2 {
    display: flex;
    align-items: center;
    flex-direction: column;
    justify-content: center;
    gap: 8px;
    color: #333;
    margin-top: 0;
    margin-bottom: 6px;
    font-size: 24px;
    text-shadow: none;}

.modal-message {
    color: #666;
    margin-bottom: 15px;
    font-size: 16px;
    text-align: center;
    font-weight: 600;}

#modalInput {
    width: 100%;
    box-sizing: border-box;
    margin: 0;
    font-size: 24px;}

.modal-buttons {
    display: flex;
    gap: 10px;
    margin-top: 16px;}

.modal-buttons button {flex: 1; margin: 0;}

.modal-cancel {background-color: #6C757D;}

.modal-confirm {background-color: #28A745;}  

.modal-danger {background-color: #DC3545;}

.modal-warning {background-color: #FFD54F; color: black;}

.modal-success {background-color: #28A745;}

.history-form {
    display: none;
    text-align: left;
    margin-top: 10px;}

.history-form label {
    display: block;
    margin-top: 14px;
    margin-bottom: 6px;
    color: #333;
    font-size: 14px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: .5px;}

.history-form input[type="text"],
.history-form input[type="number"] {
    width: 100%;
    box-sizing: border-box;
    margin: 0;
    padding: 12px;
    font-size: 18px;
    font-weight: 600;
    text-align: left;
    border: 1px solid #D0D5DD;
    border-radius: 10px;
    background-color: white;
    color: black;}

.history-checkbox {
    display: flex !important;
    align-items: center;
    gap: 10px;
    margin-top: 24px;
    padding: 12px;
    background-color: #F5F5F5;
    border-radius: 10px;
    color: #333;
    font-size: 16px;
    text-transform: none !important;
    letter-spacing: normal !important;}

.history-mode {max-width: 450px;}

.history-checkbox input {width: auto; margin: 0;}

.history-form-title {
    text-align: center;
    font-size: 24px;
    font-weight: 700;
    color: #7952B3;
    margin-bottom: 4px;}

.history-form-date {
    text-align: center;
    display: block;
    width: fit-content;
    margin: 0 auto 18px auto;
    background: #F5F5F5;
    padding: 4px 10px;
    border-radius: 8px;}

.history-time-row {display: flex; gap: 12px;}

.history-time-group {flex: 1;}

.toast {
    position: fixed;
    bottom: 25px;
    left: 50%;
    transform: translateX(-50%);
    background: linear-gradient(180deg,#343A40,#212529);
    color: white;
    padding: 12px 18px;
    border-radius: 12px;
    font-size: 15px;
    font-weight: 600;
    box-shadow: 0 8px 20px rgba(0,0,0,.35);
    z-index: 10000;
    opacity: 0;
    transition: opacity .2s ease, transform .2s ease;}

.toast.show {opacity: 1; transform:translateX(-50%) translateY(0);}

.toast i {margin-right: 8px;}

.toast.success {background: linear-gradient(180deg,#198754,#146c43);}

.toast.warning {background: linear-gradient(180deg,#fd7e14,#e8590c);}

.toast.danger {background: linear-gradient(180deg,#dc3545,#b02a37);}

.toast.info {background: linear-gradient(180deg,#343a40,#212529);}

.history-dashboard {
    display: grid;
    grid-template-columns:
        repeat(auto-fit, minmax(160px, 1fr));
    gap: 12px;
    margin-bottom: 20px;}

.history-stat-card {
    background: white;
    border-radius: 12px;
    padding: 14px;
    text-align: center;
    box-shadow: 0 2px 8px rgba(0,0,0,.08);
    min-height: 110px;}

.history-stat-card i {font-size: 24px; margin-bottom: 10px;}

.history-stat-value {
    font-size: 40px;
    font-weight: 700;
    color: #222;}

.history-stat-label {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    font-weight: 600;
    margin-bottom: 10px;
    color: #666;
    font-size: 14px;}

.history-stat-date {
    margin-top: 8px;
    font-size: 13px;
    color: #777;}

.history-stat-fastest i {color: #f0b429;}

.history-stat-busiest i {color: #4c6ef5;}

.history-stat-rain i {color: #0ea5e9;}

.history-stat-alerts i {color: #f59f00;}

.history-stat-fastest .history-stat-value {color: #f0b429;}

.history-stat-busiest .history-stat-value {color: #4c6ef5;}

.history-stat-rain .history-stat-value {color: #0ea5e9;}

.history-stat-alerts .history-stat-value {color: #f59f00;}

.history-stat-card {
    transition:
        transform .15s ease,
        box-shadow .15s ease;}

.history-stat-card:hover {transform: translateY(-2px);}

.latest-badge i,
.fastest-badge i,
.busiest-badge i,
.edited-badge i,
.rain-badge i {margin-right: 4px; font-size: 10px;}

.history-stat-fastest,
.history-stat-busiest {cursor: pointer;}

.history-card-highlight {animation: historyHighlight 2s ease;}

@keyframes historyHighlight {
    0% {box-shadow: 0 0 0 4px
            rgba(255,193,7,.8);}
    100% {box-shadow:0 0 0 0 rgba(255,193,7,0);}}

.empty-history-card {text-align: center;}

.empty-history-card i {margin-right: 8px; color: #888;}

.settings-saved { background: #198754 !important; color: white !important;}

@keyframes modalPop {
    from {opacity: 0; transform: translateY(12px) scale(.96);}
    to {opacity: 1; transform: translateY(0) scale(1);}}

.app-modal-content h2 i {
    font-size: 30px;
    margin-bottom: 4px;
    color: #4A7DFF;}

.app-modal-content h2 .fa-pen {color: #4A7DFF;}

.app-modal-content h2 .fa-trash,
.app-modal-content h2 .fa-trash-can {color: #DC3545;}

.app-modal-content h2 .fa-triangle-exclamation {color: #FD7E14;}

.app-modal-content h2 .fa-magnifying-glass {color: #7952B3;}

.modal-confirm:hover,
.modal-danger:hover,
.modal-warning:hover,
.modal-success:hover {filter: brightness(1.08);}

.settings-inline-row {justify-content: space-between;}

.settings-inline-row label {width: auto;}

.settings-inline-row input {
    width: 70px;
    max-width: 70px;
    text-align: center;}

.page-login {
    margin: 0;
    min-height: 100vh;
    display: flex;
    justify-content: center;
    align-items: center;
    background:
        linear-gradient(135deg,#244B74,#4A7DFF);}

.login-container {width: 100%; padding: 20px;}

.login-card {
    max-width: 400px;
    width: 100%;
    box-sizing: border-box;
    margin: 0 auto;
    background: white;
    border-radius: 20px;
    padding: 30px;
    box-shadow: 0 12px 30px rgba(0,0,0,.15);}

.login-logo {
    text-align: center;
    font-size: 54px;
    color: #4A7DFF;
    margin-bottom: 15px;}

.login-card h1 {text-align: center; margin-bottom: 5px;}

.login-subtitle {
    text-align: center;
    color: #666;
    margin-bottom: 20px;}

.login-field {margin-bottom: 5px;}

.login-field label {
    display: block;
    margin-bottom: -10px;
    font-weight: 600;
    color: #244B74;}

.btn-login {
    width: 100%;
    background: #4A7DFF;
    color: white;
    border: none;
    border-radius: 12px;
    padding: 14px;
    font-size: 16px;
    cursor: pointer;}

.login-help {
    text-align: center;
    margin-top: 20px;
    color: #777;
    font-size: 14px;}

.login-field input {
    width: 100%;
    text-align: left;
    box-sizing: border-box;
    padding: 12px;
    border: 2px solid #d9d9d9;
    border-radius: 10px;
    background: white;
    color: #333;}

.login-field input:focus {
    outline: none;
    border-color: #4A7DFF;
    box-shadow: 0 0 0 3px rgba(74,125,255,.15);}

.page-splash {
    margin: 0;
    min-height: 100vh;
    display: flex;
    justify-content: center;
    align-items: center;
    background: linear-gradient(135deg,#244B74,#4A7DFF);}

.splash-content {
    text-align: center;
    color: white;
    transform: translateY(-30px);}

.splash-icon {
    font-size: 72px;
    margin-bottom: 20px;
    animation:
        splashFloat 1.5s
        ease-in-out
        infinite
        alternate;}

.splash-content h1 {margin: 0 0 10px;}

.splash-content p {margin: 0; opacity: .9;}

@keyframes splashFloat {
    from {transform: translateY(0);}
    to {transform: translateY(-10px);}}

.fade-in {animation: fadeIn .5s ease;}

.fade-out {animation: fadeOut .4s ease forwards;}

@keyframes fadeIn {
    from {opacity: 0;}
    to {opacity: 1;}}

@keyframes fadeOut {
    from {opacity: 1;}
    to {opacity: 0;}}

.settings-admin-notice {
    max-width: 625px;
    margin: 0 auto 20px auto;
    background: #fff3cd;
    color: #856404;
    border: 1px solid #ffe69c;
    border-radius: 12px;
    padding: 12px;
    text-align: center;}

.settings-admin-subtitle {
    margin-top: 6px;
    font-size: .9rem;
    font-weight: normal;}

.hidden {display: none;}

.btn-demo {
    width: 100%;
    background: linear-gradient(180deg,#FFD54F,#E6B93C);
    color: #333;}

.demo-banner {
    max-width: 500px;
    margin: 10px auto;
    padding: 12px;
    border-radius: 12px;
    background: #fff3cd;
    color: #856404;
    border: 1px solid #ffe69c;
    text-align: center;}

.demo-banner i {
    color: #4A7DFF;
    font-size: 24px;
    display: block;
    margin-bottom: 6px;}

.demo-title {
    font-size: 18px;
    font-weight: 800;
    line-height: 1.1;
    margin-bottom: 4px;}

.demo-subtitle {
    font-size: 15px;
    font-weight: 700;
    line-height: 1.2;}

.demo-banner {position: relative;}

.demo-banner-close {
    position: absolute;
    top: 8px;
    right: 8px;
    width: 24px;
    height: 24px;
    padding: 0;
    margin: 0;
    background: transparent;
    border: none;
    box-shadow: none;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    color: #8a6d00;
    opacity: 0.7;}

.demo-banner-close i {
    font-size: 18px;
    line-height: 1;
    position: relative;
    top: 3px;}

.demo-banner-close:hover {opacity: 1; transform: scale(1.1);}

.trial-banner {

    max-width: 700px;
    margin: 15px auto;
    padding: 12px;

    border-radius: 12px;

    text-align: center;

    font-weight: 700;

    background: #e8f5e9;
    color: #1b5e20;

    border: 2px solid #43a047;

}

.trial-banner.expiring {

    background: #fff8e1;
    color: #e65100;

    border-color: #f9a825;

}

.trial-banner.expired {

    background: #ffebee;
    color: #b71c1c;

    border-color: #d32f2f;

}


.spot-type-options {

    display: flex;

    width: 210px;

    margin-top: 4px;

}

.spot-type-options input {
    display: none;
}

.spot-type-btn {

    flex: 1;

    text-align: center;

    padding: 10px 0;

    font-size: 12px;

    font-weight: 700;

    background: rgba(255,255,255,.08);

    border: 1px solid rgba(255,255,255,.15);

    color: white;

    cursor: pointer;

    box-sizing: border-box;

    transition:
        background .15s ease,
        color .15s ease;

}

.spot-type-btn:first-of-type {

    border-radius: 12px 0 0 12px;

}

.spot-type-btn:last-of-type {

    border-radius: 0 12px 12px 0;

}

#spotNumbers:checked + .spot-type-btn,
#spotColors:checked + .spot-type-btn {

    background: #4A7DFF;

    color: white;

    box-shadow:
        inset 0 2px 4px rgba(0,0,0,.15);

}

.billing-card h2 {

    color: #222 !important;

}

.trial-hero {

    max-width: 600px;
    width: 100%;

    margin: 20px auto;

    background:
        linear-gradient(
            135deg,
            #2e7d32,
            #43a047
        );

    color: white;

    padding: 24px;

    border-radius: 18px;

    box-sizing: border-box;

}

.trial-plan {

    font-size: 1.2rem;
    font-weight: 700;

}

.trial-days {

    font-size: 2rem;
    font-weight: 800;

    margin: 10px 0;

}

.trial-date {

    opacity: .9;

}

.trial-progress {

    margin-top: 15px;

    height: 12px;

    background:
        rgba(
            255,
            255,
            255,
            .25
        );

    border-radius: 10px;

    overflow: hidden;

}

.trial-progress-fill {

    height: 100%;

    background:
        linear-gradient(
            90deg,
            #FFD54F,
            #FFF176
        );

    transition:
        width .5s ease;

}

.billing-features {

    display: grid;

    grid-template-columns:
        repeat(
            auto-fit,
            minmax(220px, 1fr)
        );

    gap: 12px;

    list-style: none;

    padding: 0;

}

.billing-features li {

    color: #222;

    font-weight: 600;

}

.billing-card {

    max-width: 600px;

}

.billing-card:last-child {

    padding-bottom: 0px;

}

.signup-link {

    display: block;

    margin-top: 20px;

    color: #4A7DFF;

    font-weight: 700;

    text-decoration: none;

}

.signup-link:hover {

    text-decoration: underline;

}

.district-signup {

    margin-top: 20px;

    padding-top: 20px;

    border-top: 1px solid #ddd;

    text-align: center;

}

.district-signup p {

    color: #666;

    margin: 8px 0 12px 0;

    font-size: 14px;

}

.district-signup strong {

    color: #244B74;

    display: block;

    margin-bottom: 8px;

    font-size: 16px;

    font-weight: 700;

}

input,
textarea {
    font-size: 16px;
}


