body {
    font-family: Arial, sans-serif;
    text-align: center;
    margin: 0;
    padding: 0;
    background: linear-gradient(135deg, #edb305, #1a1a1a);
    color: white;
}

/* Main container */
.container {
    margin-top: 70px;
    background: rgba(255, 255, 255, 0.15);
    padding: 25px;
    display: inline-block;
    border-radius: 15px;
    box-shadow: 0 8px 25px rgba(0,0,0,0.3);
    backdrop-filter: blur(10px);
}

/* Heading */
h2 {
    font-size: 28px;
    background: linear-gradient(to right, #ffecd2, #fcb69f);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

/* Input */
input {
    padding: 10px;
    border-radius: 8px;
    border: none;
    margin-top: 10px;
}

/* Buttons */
button {
    padding: 10px 18px;
    margin: 8px;
    border: none;
    border-radius: 8px;
    cursor: pointer;
    font-weight: bold;
    background: linear-gradient(45deg, #ff6a00, #ee0979);
    color: white;
    transition: 0.3s;
}

button:hover {
    transform: scale(1.05);
}

/* Result box */
#result {
    margin-top: 15px;
    padding: 15px;
    background: rgba(0,0,0,0.2);
    border-radius: 10px;
}

/* About section */
.about {
    margin-top: 20px;
    padding: 15px;
    background: rgba(255,255,255,0.2);
    border-radius: 12px;
}

/* Page fade-in animation */
body {
    animation: fadeIn 1s ease-in;
}

@keyframes fadeIn {
    from { opacity: 0; transform: scale(0.98); }
    to { opacity: 1; transform: scale(1); }
}

/* Container animation */
.container {
    animation: slideUp 1s ease;
}

@keyframes slideUp {
    from { transform: translateY(40px); opacity: 0; }
    to { transform: translateY(0); opacity: 1; }
}

/* Result box animation */
.box {
    margin-top: 15px;
    padding: 15px;
    border-radius: 12px;
    background: rgba(0,0,0,0.2);
    animation: pop 0.5s ease;
}

@keyframes pop {
    from { transform: scale(0.8); opacity: 0; }
    to { transform: scale(1); opacity: 1; }
}

/* Countdown styling */
#countdown {
    margin-top: 10px;
    font-weight: bold;
    color: #ffe082;
}

/* Container for cards */
.age-card-container {
    display: flex;
    justify-content: center;
    gap: 15px;
    margin-top: 20px;
    flex-wrap: wrap;
}

/* Common card design */
.age-card {
    width: 120px;
    padding: 15px;
    border-radius: 15px;
    text-align: center;
    color: white;
    box-shadow: 0 8px 20px rgba(0,0,0,0.3);
    transition: 0.3s;
    animation: pop 0.5s ease;
}

/* Hover effect */
.age-card:hover {
    transform: translateY(-5px) scale(1.05);
}

/* Different colors for each card */
.years {
    background: linear-gradient(45deg, #ff6a00, #ee0979);
}

.months {
    background: linear-gradient(45deg, #2193b0, #6dd5ed);
}

.days {
    background: linear-gradient(45deg, #11998e, #38ef7d);
}

/* Numbers styling */
.age-card p {
    font-size: 28px;
    font-weight: bold;
    margin: 10px 0 0;
}

/* Title */
.age-card h3 {
    margin: 0;
    font-size: 16px;
    opacity: 0.9;
}

.final-msg {
    margin-top: 20px;
    padding: 12px;
    font-size: 18px;
    font-weight: bold;
    text-align: center;
    color: #fff;
    background: linear-gradient(45deg, #ff6a00, #ee0979, #2193b0);
    border-radius: 12px;
    animation: glow 2s ease-in-out infinite alternate;
}

@keyframes glow {
    from { transform: scale(1); box-shadow: 0 0 10px rgba(255,255,255,0.2); }
    to { transform: scale(1.05); box-shadow: 0 0 25px rgba(255,255,255,0.6); }
}

.heart {
    position: fixed;
    top: -10px;
    font-size: 20px;
    animation: fall linear forwards;
    color: red;
    z-index: 999;
}

@keyframes fall {
    to {
        transform: translateY(100vh);
        opacity: 0;
    }
}

.user-info {
    margin-bottom: 15px;
    padding: 10px;
    border-radius: 10px;
    background: rgba(255,255,255,0.2);
    animation: pop 0.5s ease;
}

.user-info h3 {
    margin: 0;
    color: #fff;
}

.user-info p {
    margin: 5px 0 0;
    font-size: 14px;
}

button:last-child {
    background: linear-gradient(45deg, #333, #666);
}

button:last-child:hover {
    transform: scale(1.05);
}

input[type="radio"] {
    margin: 5px;
    transform: scale(1.2);
    cursor: pointer;
}

label {
    margin-right: 10px;
    color: white;
    font-size: 14px;
}

/* Hide default radio */
input[type="radio"] {
    display: none;
}

/* Custom label button */
input[type="radio"] + label {
    display: inline-block;
    padding: 8px 15px;
    margin: 5px;
    border-radius: 20px;
    border: 2px solid white;
    cursor: pointer;
    transition: 0.3s;
    color: white;
    font-weight: bold;
    position: relative;
}

/* Hover effect */
input[type="radio"] + label:hover {
    transform: scale(1.05);
    background: rgba(255,255,255,0.2);
}

/* Selected state animation */
input[type="radio"]:checked + label {
    background: linear-gradient(45deg, #ff6a00, #ee0979);
    border: none;
    box-shadow: 0 0 15px rgba(255, 255, 255, 0.6);
    transform: scale(1.1);
}

/* Small pulse animation when selected */
input[type="radio"]:checked + label {
    animation: pulse 0.4s ease;
}

@keyframes pulse {
    0% { transform: scale(1); }
    50% { transform: scale(1.15); }
    100% { transform: scale(1.1); }
}

@media (max-width: 600px) {

    .container {
        width: 90%;
        margin-top: 40px;
        padding: 15px;
    }

    input, select {
        width: 100%;
    }

    .age-card-container {
        flex-direction: column;
        align-items: center;
    }

    .age-card {
        width: 80%;
    }

    button {
        width: 100%;
        font-size: 16px;
        padding: 12px;
        margin-top: 10px;
    }
}