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

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

:root {
    --orange: hsl(25, 97%, 53%);
    --white: hsl(0, 0%, 100%);
    --light-grey: hsl(217, 12%, 63%);
    --medium-grey: hsl(216, 12%, 54%);
    --dark-blue: hsl(213, 19%, 18%);
    --very-dark-blue: hsl(216, 12%, 8%); /* not really used */
    --darkest-blue: hsl(228, 11%, 9%); /* added this for background color */
    --dark-blue-variant: hsl(215, 20%, 16%); /* added this for panel gradient */
    --very-dark-blue-variant: hsl(220, 21%, 11%); /* added this for panel gradient */
    --warning-red: firebrick;
}

body {
    font-family: 'Overpass', sans-serif;
    display: flex;
    align-items: center;
    justify-content: center;
    min-height: 100vh;
    background-color: var(--darkest-blue);
}

main {
    max-width: 26rem;
    min-width: 20.4375rem;
    background: var(--very-dark-blue);
    background-image: linear-gradient(var(--dark-blue-variant), var(--very-dark-blue-variant));
    border-radius: 1.5rem;
    padding: 1.5rem;
    margin: 1.5rem;
    position: relative;
}

.star {
    padding: 1rem;
    margin-bottom: 1rem;
    background-color: var(--dark-blue);
    border-radius: 50%;
}

h1 {
    color: var(--white);
    font-size: 1.5rem;
    margin-bottom: 0.5rem;
}

p {
    font-size: 0.8rem;
    line-height: 1.5rem;
    color: var(--light-grey);
}

.rating-container {
    display: flex;
    justify-content: space-between;
    padding: 1.8rem 0;
}

.rate {
    width: 2.6rem;
    height: 2.6rem;
    padding: 0.8625rem;
    text-align: center;
    font-size: 0.875rem;
    font-weight: 700;
    color: var(--light-grey);
    background: var(--dark-blue);
    border-radius: 50%;
    cursor: pointer;
    border: 0;
}

.rate:hover {
    color: var(--white);
    background-color: var(--orange);
}

.rate:focus {
    color: var(--white);
    background-color: var(--medium-grey);
}

button.submit {
    width: 100%;
    height: 2.8rem;
    font-size: 0.9375rem;
    font-family: inherit;
    letter-spacing: 0.14rem;
    font-weight: 700;
    text-transform: uppercase;
    color: var(--white);
    background-color: var(--orange);
    padding: 1rem;
    border: 0;
    border-radius: 2rem;
    cursor: pointer;
}

button.submit:hover {
    color: var(--orange);
    background-color: var(--white);
}

button.warning, button.warning:hover {
    background-color: var(--warning-red);
    color: var(--white);
}

#feedback-panel {
    visibility: hidden;
    position: absolute;
    top: 2.2rem;
    left: 2.2rem;
    right: 2.2rem;
    bottom: 2.2rem;
    text-align: center;
}

#feedback-text {
    color: var(--orange);
    display: block;
    background-color: var(--dark-blue);
    padding: 0.5rem;
    margin: 2rem 0;
    border-radius: 1rem;
    font-size: 0.9375rem;
}


/* small modifications for non-mobile views */

@media (min-width: 26rem) {
    main {
        padding: 2.2rem;
    }
    .star {
        margin-bottom: 1.5rem;
    }
    h1 {
        font-size: 1.75rem;
    }
    p {
        font-size: 0.9375rem;
    }
    .rate {
        font-size: 1rem;
        width: 3.2rem;
        height: 3.2rem;
        padding: 1.1rem;
    }
}