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

body {
    font-family: 'GoBold', sans-serif;
    background-color: #000000;
    color: #ffffff;
    min-height: 100vh;
    display: flex;
    justify-content: center;
    align-items: center;
    overflow: hidden;
}

/* Mobile Warning Message */
.mobile-warning {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: #000000;
    z-index: 10000;
    display: flex;
    justify-content: center;
    align-items: center;
    padding: 20px;
}

.mobile-warning.hidden {
    display: none;
}

.mobile-warning-content {
    text-align: center;
    max-width: 500px;
    padding: 40px;
    background-color: #333333;
    border-radius: 20px;
    border: 2px solid #007bff;
}

.mobile-warning-logo {
    max-width: 150px;
    height: auto;
    margin: 0 auto 30px auto;
    display: block;
}

.mobile-warning-title {
    font-family: 'Anton', 'Arial Black', 'Helvetica Bold', 'Impact', 'Franklin Gothic Black', 'Arial', sans-serif;
    font-size: 2.5rem;
    font-weight: 700;
    color: #007bff;
    margin-bottom: 20px;
    text-transform: uppercase;
    letter-spacing: 2px;
}

.mobile-warning-text {
    font-family: 'Anton', 'Arial Black', 'Helvetica Bold', 'Impact', 'Franklin Gothic Black', 'Arial', sans-serif;
    font-size: 1.2rem;
    color: #ffffff;
    margin-bottom: 15px;
    line-height: 1.5;
}

.mobile-warning-subtext {
    font-family: 'Anton', 'Arial Black', 'Helvetica Bold', 'Impact', 'Franklin Gothic Black', 'Arial', sans-serif;
    font-size: 1rem;
    color: #cccccc;
    line-height: 1.4;
}

.timer-container {
    width: 100%;
    max-width: 400px;
    padding: 20px;
    text-align: center;
}

/* Logo Section */
.logo-section {
    margin-bottom: 40px;
    text-align: center;
}

.wodproof-logo {
    max-width: 200px;
    height: auto;
    margin: 0 auto;
}

/* Timer Settings Interface */
.timer-settings {
    width: 100%;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    text-align: center;
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

.timer-settings.hidden {
    display: none;
}

/* Settings Header */
.settings-header {
    background-color: #333333;
    border-radius: 8px;
    padding: 15px;
    margin-bottom: 5px; /* Reduced from 10px to 5px */
    width: 100%;
    max-width: 800px;
}

.settings-title {
    font-size: 1.5rem;
    font-weight: 700;
    margin: 0 0 10px 0; /* Reduced bottom margin from 20px to 10px */
    text-align: center;
}

/* Mode Settings */
.mode-settings {
    margin-bottom: 30px;
    width: 100%;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    position: relative;
    min-height: 400px;
}

.mode-settings.hidden {
    display: none;
}

/* Time Picker */
.time-picker {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 20px; /* Reduced from 40px to 20px */
    background-color: #333333;
    border-radius: 12px;
    padding: 30px;
    margin-bottom: 30px;
    width: 100%;
    max-width: 600px;
}

.time-column {
    text-align: center;
    position: relative;
    min-width: 80px;
}

.time-placeholder {
    font-size: 1.2rem;
    color: #ffffff;
    margin-bottom: 15px;
    opacity: 0.7;
    position: absolute;
    top: 10px;
    left: 50%;
    transform: translateX(-50%);
    z-index: 5;
}

.time-numbers {
    position: relative;
    height: 200px;
    overflow-y: auto;
    scrollbar-width: none; /* Firefox */
    -ms-overflow-style: none; /* IE and Edge */
    scroll-behavior: smooth;
    padding: 40px 5px 10px 5px; /* Reduced left/right padding from 10px to 5px */
}

.time-numbers::-webkit-scrollbar {
    display: none; /* Chrome, Safari, Opera */
}

.time-number {
    font-size: 2rem;
    font-weight: 700;
    padding: 10px 0;
    color: #ffffff;
    opacity: 0.5;
    transition: all 0.3s ease;
    cursor: pointer;
    user-select: none;
    margin: 2px 0;
}

.time-number:hover {
    opacity: 0.8;
    transform: scale(1.05);
}

.time-number.selected {
    opacity: 1;
    color: #ffffff;
    background-color: #555555;
    border-radius: 8px;
    transform: scale(1.1);
}

.time-separator {
    font-size: 2rem;
    color: #ffffff;
    margin: 0 10px; /* Reduced from 20px to 10px */
    user-select: none;
    pointer-events: none;
    opacity: 0.8;
}

/* Settings Categories */
.settings-categories {
    display: flex;
    flex-direction: column;
    gap: 30px;
}

.category-item {
    text-align: center;
}

.category-label {
    font-size: 1.2rem;
    font-weight: 700;
    margin-bottom: 20px;
    color: #ffffff;
}

/* Rounds Picker */
.rounds-picker {
    background-color: #333333;
    border-radius: 12px;
    padding: 30px;
    margin-bottom: 30px;
    width: 100%;
    max-width: 200px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    position: relative;
}

.rounds-picker::before {
    content: "Rounds";
    position: absolute;
    top: 10px;
    left: 50%;
    transform: translateX(-50%);
    font-size: 1.2rem;
    color: #ffffff;
    opacity: 0.7;
    z-index: 5;
}

.rounds-numbers {
    position: relative;
    height: 200px;
    overflow-y: auto;
    scrollbar-width: none; /* Firefox */
    -ms-overflow-style: none; /* IE and Edge */
    scroll-behavior: smooth;
    text-align: center;
    padding: 40px 10px 10px 10px; /* Added top padding to make room for the label */
}

.rounds-numbers::-webkit-scrollbar {
    display: none; /* Chrome, Safari, Opera */
}

.rounds-number {
    font-size: 2rem;
    font-weight: 700;
    padding: 10px 0;
    color: #ffffff;
    opacity: 0.5;
    transition: all 0.3s ease;
    cursor: pointer;
    user-select: none;
}

.rounds-number:hover {
    opacity: 0.8;
    transform: scale(1.05);
}

.rounds-number.selected {
    opacity: 1;
    color: #ffffff;
    background-color: #555555;
    border-radius: 8px;
    transform: scale(1.1);
}

/* Set Time Button */
.set-time-btn {
    font-family: 'Anton', 'Arial Black', 'Helvetica Bold', 'Impact', 'Franklin Gothic Black', 'Arial', sans-serif;
    font-size: 1.2rem;
    font-weight: 400;
    color: #ffffff;
    background-color: #0066ff;
    border: none;
    border-radius: 8px;
    cursor: pointer;
    margin: 5px 0 30px 0; /* Reduced top margin from 15px to 5px */
    padding: 16px 32px;
    transition: all 0.3s ease;
    text-transform: none;
    letter-spacing: 0.5px;
    min-width: 200px;
    display: block;
    margin-left: auto;
    margin-right: auto;
}

.set-time-btn:hover {
    background-color: #0052cc;
    transform: scale(1.05);
}

/* Timer Interface */
.timer-interface {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    text-align: center;
    width: 100vw;
    height: 100vh;
    display: flex;
    flex-direction: column;
    align-items: center;
    margin: 0;
    padding: 0; /* Remove all padding */
    box-sizing: border-box;
    overflow: hidden;
}

.timer-interface.hidden {
    display: none;
}

/* First Screen Logo - Only visible on initial screen */
.first-screen-logo {
    text-align: center;
    padding: 40px 0 30px 0;
    margin-bottom: 20px;
}

.first-screen-logo .wodproof-logo {
    max-height: 120px;
    max-width: 300px;
    object-fit: contain;
}

/* Hide first screen logo when timer interface is shown */
.timer-interface:not(.hidden) ~ .first-screen-logo,
.timer-interface:not(.hidden) .first-screen-logo,
body.timer-active .first-screen-logo {
    display: none !important;
}

/* Alternative approach - hide first screen logo when timer modes are hidden */
.timer-modes.hidden + .first-screen-logo,
.timer-modes.hidden ~ .first-screen-logo {
    display: none !important;
}

/* Timer Logo Section - Top of timer screen */
.timer-logo-section {
    height: 12vh;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    width: 100%;
    text-align: center;
    padding: 0;
    margin: 0;
    order: 1;
    padding-top: 40px; /* Added padding to align logo with back button line */
}

.timer-wodproof-logo {
    max-height: 80%;
    max-width: 80%;
    object-fit: contain;
}

/* Round Status Display */
.round-status {
    position: absolute;
    bottom: 40px;
    right: 40px;
    font-family: 'Anton', 'Arial Black', 'Helvetica Bold', 'Impact', 'Franklin Gothic Black', 'Arial', sans-serif;
    font-size: 1.8rem; /* Increased from 1.2rem to 1.8rem */
    font-weight: 400;
    color: #ffffff;
    text-align: center;
    z-index: 15;
    background-color: rgba(0, 0, 0, 0.8);
    padding: 12px 20px; /* Increased padding for bigger size */
    border-radius: 25px; /* Increased border radius */
    white-space: nowrap;
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.5);
}

/* Timer Display - Break free from container constraints */
.timer-display {
    position: relative;
    height: 40vh; /* Reduced from 45vh to 40vh to bring buttons closer */
    width: 100vw;
    text-align: center;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    overflow: visible;
    order: 2;
    padding: 0;
    margin: 0;
}

.timer-numbers {
    position: absolute;
    top: 60%;
    left: 50%;
    transform: translate(-50%, -50%) scale(1); /* Reduced from scale(1.2) to scale(1) for smaller size */
    font-family: 'Anton', 'Arial Black', 'Helvetica Bold', 'Impact', 'Franklin Gothic Black', 'Arial', sans-serif;
    font-size: 20rem;
    font-weight: 400;
    color: #ffffff;
    letter-spacing: 10px;
    line-height: 1;
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 15px;
    white-space: nowrap;
    padding: 0;
    margin: 0;
    z-index: 10;
}

.timer-numbers .minutes,
.timer-numbers .seconds {
    min-width: 200px;
    text-align: center;
    flex-shrink: 0;
    padding: 0;
    margin: 0;
}

.timer-numbers .colon {
    font-size: 18rem;
    opacity: 0.8;
    flex-shrink: 0;
    padding: 0;
    margin: 0;
}

.minutes, .seconds {
    display: inline-block;
    min-width: 120px;
}

.colon {
    display: inline-block;
    margin: 0 10px;
    font-size: 5rem;
    vertical-align: top;
    margin-top: -5px;
}

/* Start/Stop Button */
.start-stop-btn {
    background: #ffffff;
    color: #000000;
    border: none;
    border-radius: 50%;
    width: 120px;
    height: 120px;
    font-family: 'Anton', 'Arial Black', 'Helvetica Bold', 'Impact', 'Franklin Gothic Black', 'Arial', sans-serif;
    font-size: 24px;
    font-weight: 400;
    cursor: pointer;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    padding: 0;
    margin: 0;
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.3);
}

.start-stop-btn:hover {
    transform: scale(1.05);
    box-shadow: 0 6px 12px rgba(0, 0, 0, 0.4);
}

.start-stop-btn:active {
    transform: scale(0.95);
}

/* Stop state - red text, white background */
.start-stop-btn.stop {
    background: #ffffff;
    color: #ff0000;
}

/* Timer Controls */
.timer-controls {
    height: 23vh;
    display: flex;
    align-items: flex-end;
    justify-content: center;
    padding-bottom: 20px;
    flex-shrink: 0;
    width: 100%;
    text-align: center;
    order: 4;
}

/* Timer Modes */
.timer-modes {
    margin-bottom: 30px;
}

.mode-section {
    margin-bottom: 15px;
    border: 1px solid #333333;
    border-radius: 8px;
    overflow: hidden;
    transition: all 0.3s ease;
}

.mode-section:hover {
    border-color: #ffffff;
    transform: translateY(-2px);
}

.mode-option {
    padding: 20px;
    cursor: pointer;
    font-size: 1rem;
    font-weight: 700;
    letter-spacing: 0.5px;
    transition: all 0.3s ease;
}

.mode-option:hover {
    background-color: #ffffff;
    color: #000000;
}

.mode-option.active {
    background-color: #0066ff;
    color: #ffffff;
    border-color: #0066ff;
}

/* Current Mode Display */
.current-mode {
    padding: 15px;
    background-color: #0066ff;
    border-radius: 8px;
    margin-bottom: 20px;
}

.mode-label {
    font-size: 1rem;
    font-weight: 700;
    letter-spacing: 0.5px;
}

/* Utility Classes */
.hidden {
    display: none;
}

/* Responsive Design */
@media (max-width: 480px) {
    .wodproof-logo {
        max-width: 150px;
    }
    
    .timer-numbers {
        font-size: 4rem;
    }
    
    .minutes, .seconds {
        min-width: 80px;
    }
    
    .colon {
        font-size: 3.5rem;
        margin: 0 5px;
    }
    
    .control-btn {
        font-size: 1rem;
        padding: 12px 24px;
        margin: 0 5px;
    }
    
    .mode-option {
        font-size: 0.9rem;
        padding: 15px;
    }
    
    .time-picker {
        padding: 20px;
        gap: 15px;
    }
    
    .time-numbers {
        height: 150px;
    }
    
    .time-number {
        font-size: 1.5rem;
        padding: 8px 0;
    }
    
    .rounds-numbers {
        height: 150px;
    }
    
    .rounds-number {
        font-size: 1.5rem;
        padding: 8px 0;
    }
}

/* Animation for timer running */
.timer-running .timer-numbers {
    /* Removed pulsing animation - timer no longer flashes */
}

/* Countdown warning */
.countdown-warning .timer-numbers {
    color: #ff0000;
    animation: warning-pulse 0.5s infinite;
}

@keyframes warning-pulse {
    0% { opacity: 1; }
    50% { opacity: 0.5; }
    100% { opacity: 1; }
}

/* Countdown Preset Button */
.countdown-preset-btn {
    font-family: 'Anton', 'Arial Black', 'Helvetica Bold', 'Impact', 'Franklin Gothic Black', 'Arial', sans-serif; /* Anton as primary font */
    font-size: 1.2rem;
    font-weight: 400; /* Anton works best with normal weight */
    padding: 16px 32px;
    background-color: #0066ff;
    color: #ffffff;
    border: none;
    border-radius: 10px;
    cursor: pointer;
    transition: all 0.3s ease;
    text-transform: none;
    letter-spacing: 0.5px;
    min-width: 220px;
}

.countdown-preset-btn:hover {
    background-color: #0052cc;
    transform: scale(1.05);
}

/* Countdown Section - Below timer, positioned lower towards start button */
.countdown-preset {
    height: 25vh; /* Increased from 20vh to 25vh to move countdown lower */
    display: flex;
    align-items: flex-end; /* Changed from flex-start to flex-end to position button lower */
    justify-content: center;
    margin: 0;
    text-align: center;
    flex-shrink: 0;
    order: 3;
    padding-bottom: 20px; /* Changed from padding-top to padding-bottom to position button lower */
}

/* Start Button Section - Positioned even higher (unchanged) */
.timer-controls {
    height: 23vh; /* Reduced from 28vh to 23vh to bring countdown closer */
    display: flex;
    align-items: flex-start;
    justify-content: center;
    margin: 0;
    text-align: center;
    flex-shrink: 0;
    order: 4;
    padding-top: 20px; /* Padding to position button higher in its section */
}

/* Back Button */
.back-btn {
    font-family: 'Anton', 'Arial Black', 'Helvetica Bold', 'Impact', 'Franklin Gothic Black', 'Arial', sans-serif; /* Anton as primary font */
    font-size: 1.1rem;
    font-weight: 400; /* Anton works best with normal weight */
    padding: 12px 24px;
    background-color: transparent;
    color: #ffffff;
    border: 2px solid #ffffff;
    border-radius: 8px;
    cursor: pointer;
    transition: all 0.3s ease;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.back-btn:hover {
    background-color: #ffffff;
    color: #000000;
}

.back-btn.top-right {
    position: absolute;
    top: 40px;
    left: 40px;
    z-index: 10;
}

/* Responsive Design for Web */
@media (max-width: 1400px) {
    .timer-interface {
        padding: 35px;
    }
    
    .timer-numbers {
        font-size: 7rem;
    }
    
    .timer-numbers .minutes,
    .timer-numbers .seconds {
        min-width: 110px;
    }
    
    .timer-numbers .colon {
        font-size: 5rem;
    }
}

@media (max-width: 1200px) {
    .timer-interface {
        padding: 30px;
    }
    
    .timer-numbers {
        font-size: 6rem;
    }
    
    .timer-numbers .minutes,
    .timer-numbers .seconds {
        min-width: 100px;
    }
    
    .timer-numbers .colon {
        font-size: 4rem;
    }
    
    .start-btn {
        width: 130px;
        height: 130px;
    }
}

@media (max-width: 768px) {
    .timer-interface {
        padding: 25px;
    }
    
    .timer-numbers {
        font-size: 4rem;
        letter-spacing: 2px;
        gap: 8px;
    }
    
    .timer-numbers .minutes,
    .timer-numbers .seconds {
        min-width: 80px;
    }
    
    .timer-numbers .colon {
        font-size: 3rem;
    }
    
    .countdown-preset-btn {
        min-width: 200px;
        font-size: 1.2rem;
        padding: 15px 30px;
    }
    
    .start-btn {
        width: 120px;
        height: 120px;
        font-size: 1.1rem;
    }
    
    .control-btn {
        font-size: 1.1rem;
        padding: 15px 30px;
        margin: 0 10px;
    }
}

@media (max-width: 480px) {
    .timer-interface {
        padding: 20px;
    }
    
    .timer-numbers {
        font-size: 3rem;
        letter-spacing: 1px;
        gap: 6px;
    }
    
    .timer-numbers .minutes,
    .timer-numbers .seconds {
        min-width: 60px;
    }
    
    .timer-numbers .colon {
        font-size: 2.5rem;
    }
    
    .back-btn.top-right {
        top: 20px;
        left: 20px;
    }
}

/* Countdown Sequence Styling */
.countdown-sequence .timer-numbers {
    color: #007bff; /* Blue color during countdown */
    animation: countdown-pulse 0.5s ease-in-out;
}

@keyframes countdown-pulse {
    0% { transform: translate(-50%, -50%) scale(1); }
    50% { transform: translate(-50%, -50%) scale(1.1); }
    100% { transform: translate(-50%, -50%) scale(1); }
}

/* Interval Layout - Side by Side */
.interval-layout {
    position: absolute;
    left: 50%;
    top: 50%;
    transform: translate(-50%, -50%);
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    gap: 40px;
    width: auto;
    max-width: 900px;
    z-index: 10;
}

.interval-section {
    flex: 1;
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    min-width: 200px;
}

.interval-label {
    color: #ffffff;
    font-family: 'Anton', 'Arial Black', 'Helvetica Bold', 'Impact', 'Franklin Gothic Black', 'Arial', sans-serif;
    font-size: 18px;
    font-weight: 400;
    margin-bottom: 20px;
    text-transform: uppercase;
    letter-spacing: 1px;
}

/* Timer Controls */

/* Responsive Mobile Warning */
@media (max-width: 768px) {
    .mobile-warning-content {
        max-width: 90%;
        padding: 30px 20px;
        margin: 20px;
    }
    
    .mobile-warning-logo {
        max-width: 120px;
        margin-bottom: 25px;
    }
    
    .mobile-warning-title {
        font-size: 2rem;
        margin-bottom: 15px;
    }
    
    .mobile-warning-text {
        font-size: 1.1rem;
        margin-bottom: 12px;
    }
    
    .mobile-warning-subtext {
        font-size: 0.9rem;
    }
}

@media (max-width: 480px) {
    .mobile-warning-content {
        padding: 25px 15px;
        margin: 15px;
    }
    
    .mobile-warning-logo {
        max-width: 100px;
        margin-bottom: 20px;
    }
    
    .mobile-warning-title {
        font-size: 1.8rem;
        margin-bottom: 12px;
    }
    
    .mobile-warning-text {
        font-size: 1rem;
        margin-bottom: 10px;
    }
    
    .mobile-warning-subtext {
        font-size: 0.85rem;
    }
}
