/* Josh Comeau CSS reset */

/* 1. Use a more-intuitive box-sizing model */
*,
*::before,
*::after {
    box-sizing: border-box;
}

/* 2. Remove default margin */
*:not(dialog) {
    margin: 0;
}

/* 3. Enable keyword animations */
@media (prefers-reduced-motion: no-preference) {
    html {
        interpolate-size: allow-keywords;
    }
}

body {
    /* 4. Add accessible line-height */
    line-height: 1.5;
    /* 5. Improve text rendering */
    -webkit-font-smoothing: antialiased;
    min-height: 100vh;
    background: linear-gradient(in hsl, #eeeeff, 80%, #dedeff);
}

/* 6. Improve media defaults */
img,
picture,
video,
canvas,
svg {
    display: block;
    max-width: 100%;
}

/* 7. Inherit fonts for form controls */
input,
button,
textarea,
select {
    font: inherit;
}

/* 8. Avoid text overflows */
p,
h1,
h2,
h3,
h4,
h5,
h6 {
    overflow-wrap: break-word;
}

/* 9. Improve line wrapping */
p {
    text-wrap: pretty;
}
h1,
h2,
h3,
h4,
h5,
h6 {
    text-wrap: balance;
}

@font-face {
    font-family: "AVHersheySimplexHeavy";
    src: url("AVHersheySimplexHeavy.otf") format("opentype");
}
* {
    color: var(--green);
    font-family: "AVHersheySimplexHeavy", sans-serif;
}
:root {
    font-size: 18px;
    --green: green;
    --orange: #F60;
}

@media only screen and (max-width: 600px) {
    :root {
        font-size: 14px;
    }

    sl-details {
        width: 100%;
    }

    .info-leaf {
        gap: .15rem;
    }

    main {
        align-items: flex-start;
        min-height: 100vh;
        margin-top: 1rem !important;
        margin-bottom: 0;
    }
}

@media only screen and (max-width: 390px) {
    :root {
        font-size: 13px;
    }
}

@media only screen and (max-width: 370px) {
    :root {
        font-size: 12px;
    }
}

p,
button,
h1 {
    font-size: 1rem;
    font-weight: 400;
}

form h1 {
    letter-spacing: 4px;
}
/*input[type="radio"] {
    appearance: none;
    width: 1.2em;
    height: 1em;
    border: 1px solid green;
    border-radius: 45%;
    flex-shrink: 0;
    margin-top: 0.4rem;
}
input[type="radio"]:checked {
    box-shadow:
        inset 0 0 0 2px white,
        inset 0 0 0 10px green;
}*/
input[type="radio"] {
    outline: var(--green);
    width: 1.2rem;
}
input[type="radio"]:checked {
    accent-color: var(--green);
}

fieldset {
    border: none;
    padding: 0;
}
.radio-wrapper {
    display: flex;
    gap: 0.5em;
    width: 50%;
}

button, .btn {
    border: 1px solid var(--green);
    background: #FFF2;
    border-radius: 2px;
    margin: 0 auto
}
button.btn:hover {
    background: var(--green);
    color: white;
}

a.btn {
    padding: 1rem 2rem;
    text-decoration: none;
}


main {
    display: flex;
    justify-content: center;
    align-items: center;
    min-height: 100vh;
    width: 40rem;
    max-width: 100vw;
    margin: 0 auto 2rem;
}
form {
    max-width: calc(40ch+ 4rem);
    display: flex;
    flex-direction: column;
    gap: 1rem;
    padding: 2rem;
    border-right: 1px solid #7777;
    border-bottom: 1px solid gray;
    background: #EEF;
}
input[type="text"],
input[type="email"],
input[type="tel"],
textarea {
    background: transparent;
    border: none;
    border-bottom: 1.5px dashed var(--green);
    outline: none;
    width: 100%;
    color: var(--orange);
}

form label {
    display: flex;
    flex-direction: column;
}

form label:has(:required) > span::after,
form fieldset:has(:required) > legend::after {
    content: " *";
    color: var(--orange);
    vertical-align: super;
    font-size: 0.7em;
}

.small {
    font-size: 0.8rem;
}
.name-entry {
    display: flex;
    gap: 0.5em;
    margin-bottom: 0.25em;
}
.name-entry input {
    flex: 1;
}

.hidden {
    display: none !important;
}

#info-view {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.5rem;
    padding-top: 2rem;
}

.info-leaf {
    display: flex;
    gap: 2rem;
    max-width: 60ch;
}

.leaf-right,
.leaf-left {
    white-space: pre-line;
    flex: 1;
}

.leaf-right {
    text-align: right;
}

.leaf-left {
    text-align: left;
}

sl-details {
    width: 100%;
}

sl-details img {
    margin-top: 1rem;
}

.accent {
    color: var(--orange);
}

.flex {
    display: flex;
}

.flex-column {
    display: flex;
    flex-direction: column;
}

.space-between {
    justify-content: space-between;
}

.full-width {
    width: 100%;
}

.gap {
    gap: 2rem;
}

.rule {
    border: 1px dashed var(--green);
    width: 100%;
}

textarea {
    resize: vertical;
}

@keyframes load {
  from {
    opacity: 0;
    transform: translateY(20px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.load {
  animation: load 600ms ease-in-out;
}

.hover-shift {
    transform: rotateZ(0deg)
}

.hover-shift:hover {
    transform: rotateZ(10deg);
}

.page-padding {
    padding: 0rem 1rem;
}

sl-carousel {
    margin: 0 2rem;
    margin-top: 1rem;
}

sl-carousel::part(navigation-button) {
  font-size: 2rem; /* increase icon size */
}

sl-carousel-item img {
    border-right: 1px solid black;
    border-bottom: 1px solid black;
    border-top: 1px solid #FEE;
    border-left: 1px solid #FEE;
}

a {
    text-decoration-color: var(--orange);
    text-decoration-thickness: 2px;
}

.with-love {
    display: none;
}

@media only screen and (max-width: 600px) {
    .with-love {
        display: block;
        color: var(--orange);
        font-size: 0.8rem;
        text-align: center;
        margin-top: auto;
        padding-bottom: 2rem;
    }
}

.back-link {
    text-decoration: none;
    position: relative;
    margin-left: 2rem;
}

.back-link::before {
    content: "\2190 ";
    position: absolute;
    transform: translateX(-120%);
}

.stepper {
    display: flex;
    height: 1.5rem;
}

.stepper input {
    appearance: textfield;
    width: 1.5rem;
    text-align: center;
    border: 1px solid var(--green);
    border-left: 0;
    border-right: 0;
}

.stepper input::-webkit-inner-spin-button {
    -webkit-appearance: none;
}

.stepper button {
    padding: 0;
    margin: 0;
    width: 1.5rem;
    border: 1px solid var(--green);
    border-radius: 0;
    border-top-left-radius: 50%;
    border-bottom-left-radius: 50%;
    cursor: pointer;
    line-height: 0;
}

.stepper input+button {
    border-radius: 50%;
    border-top-left-radius: 0;
    border-bottom-left-radius: 0;
}

.stepper-row {
    display: flex;
    flex-direction: row-reverse;
    justify-content: space-between;
    align-items: flex-start;
    gap: 1rem;
    margin-bottom: 0.25rem;
}

.stepper-row label {
    flex: 1;
}

.stepper-row .stepper {
    flex-shrink: 0;
}

.food-grid {
    display: grid;
    grid-template-columns: auto 1fr;
    gap: 0.5rem 1rem;
    align-items: start;
}

.food-grid legend {
    grid-column: 1 / -1;
    margin-bottom: .25rem;
}
