:root {
    --bg-color: #000000;
    --text-color: #ffffff;
    --ring-1: #FA114F; /* Red */
    --ring-2: #92E82A; /* Green */
    --ring-3: #00C6FF; /* Blue */
    --ring-bg: rgba(255, 255, 255, 0.1);
}

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

body {
    font-family: -apple-system, BlinkMacSystemFont, "SF Pro Display", "Segoe UI", Roboto, sans-serif;
    background-color: var(--bg-color);
    color: var(--text-color);
    height: 100vh;
    height: 100dvh;
    overflow: hidden;
    display: flex;
    justify-content: center;
    align-items: center;
}

.app-container {
    width: 100%;
    max-width: 400px;
    height: 100%;
    display: flex;
    flex-direction: column;
    justify-content: center;
    padding: 2rem 1.5rem;
    position: relative;
}

header {
    text-align: center;
    margin-bottom: 2rem;
    margin-top: 2.5rem;
}

h1 {
    font-size: 2.5rem;
    font-weight: 800;
    margin-bottom: 0.5rem;
}

.subtitle {
    color: #888;
    font-size: 1rem;
}

.rings-container {
    flex: 1;
    display: flex;
    justify-content: center;
    align-items: center;
    position: relative;
}

.rings-svg {
    width: 100%;
    max-width: 320px;
    transform: rotate(-90deg); /* Start at 12 o'clock */
    filter: drop-shadow(0 0 10px rgba(255,255,255,0.1));
}

circle {
    fill: none;
    stroke-width: 18;
    stroke-linecap: round;
}

.ring-bg {
    stroke: var(--ring-bg);
}

/* 
  Circumference = 2 * PI * r
  r=85 -> C ≈ 534
  r=65 -> C ≈ 408
  r=45 -> C ≈ 282
*/
.ring-1 { stroke: var(--ring-1); stroke-dasharray: 534; stroke-dashoffset: 534; transition: stroke-dashoffset 0.5s ease-out; }
.ring-2 { stroke: var(--ring-2); stroke-dasharray: 408; stroke-dashoffset: 408; transition: stroke-dashoffset 0.5s ease-out; }
.ring-3 { stroke: var(--ring-3); stroke-dasharray: 282; stroke-dashoffset: 282; transition: stroke-dashoffset 0.5s ease-out; }

.actions {
    display: flex;
    justify-content: space-between;
    gap: 10px;
    margin-bottom: 2rem;
}

.action-btn {
    flex: 1;
    background: #1c1c1e;
    border: none;
    border-radius: 15px;
    padding: 1rem 0.5rem;
    color: white;
    font-size: 0.9rem;
    font-weight: 600;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 8px;
    cursor: pointer;
    transition: transform 0.1s, background 0.3s;
    -webkit-tap-highlight-color: transparent;
}

.action-btn:active {
    transform: scale(0.9);
}

.emoji {
    font-size: 2rem;
}

/* Floating messages */
#messages-container {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
    z-index: 10;
}

.floating-msg {
    position: absolute;
    background: rgba(255,255,255,0.9);
    color: #000;
    padding: 10px 15px;
    border-radius: 12px;
    font-weight: 600;
    font-size: 0.9rem;
    box-shadow: 0 4px 15px rgba(0,0,0,0.3);
    max-width: 200px;
    text-align: center;
}

/* Final Message */
#final-message {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    background: rgba(30,30,30,0.95);
    padding: 2rem;
    border-radius: 20px;
    text-align: center;
    width: 90%;
    z-index: 20;
    backdrop-filter: blur(10px);
    border: 1px solid rgba(255,255,255,0.1);
}

#final-message.hidden {
    display: none;
}

#final-message h2 {
    color: var(--ring-1);
    margin-bottom: 1rem;
    font-size: 2rem;
}

.back-btn {
    position: absolute;
    top: 15px;
    left: 15px;
    background: rgba(255,255,255,0.2);
    color: white;
    text-decoration: none;
    padding: 8px 12px;
    border-radius: 12px;
    font-weight: bold;
    z-index: 1000;
    backdrop-filter: blur(5px);
    transition: background 0.2s;
    font-size: 0.9rem;
}
.back-btn:active {
    background: rgba(255,255,255,0.4);
}
