

@import url('https://fonts.googleapis.com/css2?family=Nunito:wght@400;600;700;800&display=swap');

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

body {
    font-family: 'Nunito', sans-serif;
    min-height: 100vh;
   background: linear-gradient(180deg, #71d0ff 0%, #c2ecff 40%, #7bff80 100%);
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 2rem;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

.container {
    width: 100%;
    max-width: 480px;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 1.5rem;
}

/* TITLE */ 
.app-title {
    font-size: 2.2rem;
    font-weight: 500;
    color: #1a6fa3;
    text-shadow: 0 2px 8px rgba(100, 180, 255, 0.4);
    letter-spacing: -1px;
    animation: fadeDown 0.6s ease;
}

/* SEARCH BAR */
.search-bar {
    display: flex;
    width: 100%;
    gap: 0.5rem;
    animation: fadeUp 0.6s ease 0.2s both
}

.search-bar input {
    flex: 1;
    padding: 0.75rem 1.2rem;
    border: 2px solid rgba(255,255,255,0.8);
    border-radius: 50px;
    background: rgba(255,255,255,0.6);
    backdrop-filter: blur(16px);
    font-family: 'Nunito', sans-serif;
    font-size: 1rem;
    color: #1a4f6e;
    outline: none;
    transition: border 0.2s, box-shadow 0.2s;
    caret-color: #5bbfea;
    animation: fadeUp 0.6s ease 0.2s both;
}

.search-bar input::placeholder {
        color: #7ab8d4;
}

.search-bar input:focus {
    border-color: #27beff;
    box-shadow: 0 0 0 4px rgba(91,191,234,0.2);
}

.search-bar button {
    padding: 0.75rem 1.5rem;
    border: none;
    border-radius: 50px;
    background: linear-gradient(135deg, #5bbfea, #3a9fd4);
    color: white;
    font-family: 'Nunito', sans-serif;
    font-size: 1rem;
    cursor: pointer;
    box-shadow: 0 4px 15px rgba(58, 159, 212, 0.4);
    transition: transform 0.15s, box-shadow 0.15s;
    animation: fadeUp 0.6s ease 0.8s both;
}

.search-bar button:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 16px rgba(58,159,212,0.5);
}

.search-bar button:active {
    transform: translateY(0);
}

/* ERROR */
#error-message {
    color: #c0392b;
    background: rgba(255,255,255,0.6);
    padding: 0.6rem 1.2rem;
    border-radius: 50px;
    font-weight: 500;
    font-size: 0.9rem;
}

/* WEATHER CARD */
#weather-display {
    width: 100%;
    background: rgba(255,255,255,0.25);
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
    border: 4px solid rgba(255,255,255,0.2);
    border-radius: 28px;
    padding: 2rem;
    box-shadow:
    0 8px 32px rgba(100,180,255,0.2),
    inset 0 1px 0 rgba(255,255,255,0.8);
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.5rem;
    animation: fadeUp 0.4s ease;
}

#city-name {
    font-size: 1.8rem;
    font-weight: 500;
    color: #1a6fa3;
}

#weather-icon {
    width: 80px;
    height: 80px;
    filter: drop-shadow(0 4px 8px rgba(58,159,212,0.4));
}

#temperature {
    font-size: 2.6rem;
    font-weight: 600;
    color: #1a4f6e;
    line-height: 1;
}

#description {
    font-size: 1rem;
    font-weight: 600;
    color: #4a9abe;
}

#humidity, #wind-speed {
    font-size: 0.95rem;
    font-weight: 400;
    color: #5a8fa3;
    padding: 6px;
}

.details-row {
    display: flex;
    gap: 1rem;
    margin-top: 0.5rem;
}

.details-row p {
    background: rgba(255,255,255,0.5);
    border: 1px solid rgba(255,255,255,0.6);
    border-radius: 50px;
    padding: 0.8rem 1.6rem;
    font-size: 0.9rem;
    font-weight: 600;
    color: #4a8fa3;
}

.hidden {
    display: none !important;
}

/* SKELETON */

#skeleton {
    width: 100%;
    background: rgba(255,255,255,0.25);
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
    border: 1px solid rgba(255,255,255,0.4);
    border-radius: 28px;
    padding: 2rem;
    box-shadow: 0 8px 32px rgba(100,180,255,0.2);
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 1rem;
}

.skeleton-line {
    border-radius: 50px;
    background: linear-gradient(
        90deg,
        rgba(255,255,255,0.3) 25%,
        rgba(255,255,255,0.6) 50%,
        rgba(255,255,255,0.3) 75%
    );
    background-size: 200% 100%;
    animation: shimmer 1.5s infinite;
}

.skeleton-icon {
    width: 80px;
    height: 80px;
    border-radius: 50%;
    background: linear-gradient(
        90deg,
        rgba(255,255,255,0.3) 25%,
        rgba(255,255,255,0.6) 50%,
        rgba(255,255,255,0.3) 75%
    );
    background-size: 200% 100%;
    animation: shimmer 1.5s infinite;
    flex-shrink: 0;
}

.title {width: 40%; height: 28px;}
.temp { width: 30%; height: 48px;}
.desc {width: 50%; height: 18px;}

.skeleton-pills {
    display: flex;
    gap: 1rem;
    flex-direction: row;
}

.skeleton-pill {
    width: 100px;
    height: 32px;
    border-radius: 50px;
    background: linear-gradient(
        90deg,
        rgba(255,255,255, 0.3) 25%,
        rgba(255,255,255, 0.6) 50%,
        rgba(255,255,255,0.3) 75%
    );
    background-size: 200% 100%;
    animation: shimmer 1.5s infinite;
}


/* ANIMATION */ 
@keyframes fadeUp {
    from {opacity: 0; transform: translateY(16px);}
    to {opacity: 1; transform: translateY(0);}
}

@keyframes fadeDown {
    from {opacity: 0; transform: translateY(-16px);}
    to {opacity: 1; transform: translateY(0);}
}

@keyframes shimmer {
    0% {background-position: 200% 0;}
    100% {background-position: -200% 0;}
}

