/* ===== Reset & Base ===== */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body, html {
    height: 100%;
    font-family: 'Segoe UI', Tahoma, sans-serif;
    display: flex;
    justify-content: center;
    align-items: center;
    overflow: hidden;
}

/* ===== Background Ocean Circles ===== */
.hour-background {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: -1; /* behind everything */
    overflow: hidden;
    background: linear-gradient(to bottom, #001f3f, #004080);
}

.hour-background .circle {
    position: absolute;
    border-radius: 50%;
    border: 2px solid #0b3d91;
    background: transparent;
    opacity: 0.2;
    pointer-events: none;
    transition: all 0.3s ease;
}

/* ===== Center Container & Card ===== */
.container {
    text-align: center;
}

.card {
    backdrop-filter: blur(10px);
    background: rgba(0, 0, 0, 0.5);
    padding: 40px 60px;
    border-radius: 20px;
    color: white;
    box-shadow: 0 10px 30px rgba(0,0,0,0.3);
}

.card h1 {
    margin-bottom: 20px;
    font-size: 32px;
}

/* ===== Countdown Boxes ===== */
.countdown {
    display: flex;
    gap: 15px;
    justify-content: center;
    margin-top: 30px;
}

.time-box {
    background: rgba(255,255,255,0.1);
    backdrop-filter: blur(10px);
    padding: 15px;
    border-radius: 15px;
    width: 70px;
    text-align: center;
    color: white;
    box-shadow: 0 5px 15px rgba(0,0,0,0.2);
}

.time-box span {
    font-size: 28px;
    font-weight: bold;
    display: block;
}

.time-box label {
    font-size: 12px;
    opacity: 0.7;
}

.pop {
    transform: scale(1.2);
    transition: transform 0.15s ease;
}

/* ===== Seconds Meter ===== */
.seconds-meter {
    display: grid;
    grid-template-columns: repeat(15, 1fr);
    gap: 4px;
    width: 330px;
    margin: 20px auto;
}

.seconds-meter .square {
    width: 20px;
    height: 20px;
    background: white;
    border-radius: 3px;
    transition: background 0.2s;
}

.square {
    transition: background 0.2s, opacity 0.2s;
}

.square.red {
    box-shadow: 0 0 5px #ff4d4d;
}

/* ===== Minutes Meter ===== */
.minutes-meter {
    display: grid;
    grid-template-columns: repeat(15, 1fr);
    gap: 4px;
    width: 660px; /* larger for bigger squares */
    margin: 20px auto;
}

.minutes-meter .square {
    width: 40px;
    height: 40px;
    background: white;
    border-radius: 5px;
    transition: background 0.2s;
}

/* ===== Setup Form ===== */
#setupForm {
    position: fixed;      /* Stay relative to viewport */
    top: 50%;             /* Center vertically */
    left: 50%;            /* Center horizontally */
    transform: translate(-50%, -50%); /* Adjust for element's size */
    display: none;        /* controlled by JS */
    background: rgba(255, 255, 255, 0.95);
    padding: 30px 35px;
    border-radius: 20px;
    width: 320px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.2);
    backdrop-filter: blur(10px);
    animation: fadeIn 0.4s ease;
    z-index: 1000;        /* above everything */
}

#setupForm h2 {
    margin-top: 0;
    margin-bottom: 20px;
    text-align: center;
    color: #333;
}

#setupForm label {
    display: block;
    margin-bottom: 5px;
    font-size: 14px;
    color: #555;
}

#setupForm input {
    width: 100%;
    padding: 10px 12px;
    margin-bottom: 15px;
    border: none;
    border-radius: 10px;
    background: #f1f3f6;
    font-size: 14px;
    transition: 0.2s;
}

#setupForm input:focus {
    outline: none;
    background: #e7ecff;
    box-shadow: 0 0 0 2px #667eea;
}

#setupForm button {
    width: 100%;
    padding: 12px;
    border: none;
    border-radius: 12px;
    background: linear-gradient(135deg, #667eea, #764ba2);
    color: white;
    font-size: 15px;
    font-weight: 600;
    cursor: pointer;
    transition: transform 0.15s ease, box-shadow 0.15s ease;
}

#setupForm button:hover {
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(0,0,0,0.2);
}

#setupForm button:active {
    transform: translateY(0);
    box-shadow: none;
}

/* ===== Animations ===== */
@keyframes fadeIn {
    from { opacity: 0; transform: translateY(15px); }
    to   { opacity: 1; transform: translateY(0); }
}

/* ===== Responsive ===== */
@media (max-width: 600px) {
    .card { padding: 25px; }
    .card h1 { font-size: 24px; }
    .countdown { font-size: 20px; }
}

.footer{
    margin-top: 300px;
}