/*
    Name:       Joseph Medeiros
    Business:   Medeiros Web Design
    Date:       November 11, 2026
    Project:    Concept Site - Stonewall Pest Control (fictional business)
    Filename:   styles.css

    Layout plan: mobile-first. Dark olive with a hazard yellow accent.
    The Bug ID cards flip in 3D at 768px and up (perspective, rotateY and
    backface-visibility), on :hover and on :focus-within so keyboard users
    flip them by tabbing to the link on the back. On phones the front and
    back simply stack. The barrier diagram is a house drawn with borders
    inside a dashed circle. Season bars are spans with set widths and the
    season in words. Media queries at 576px, 768px, 992px and 1200px.

    Colors (WebAIM checked, AA):
      #1A2E05 dark olive   #3F6212 olive   #FACC15 hazard yellow (only
      behind dark text)   #F7F9F2 light   #4D5B3C muted
*/

/* ----- Browser reset (universal) ----- */

/* border-box sizing and zero default spacing. */
* {
    box-sizing: border-box;
    margin: 0px;
    padding: 0px;
}

/* ----- Page defaults (element) ----- */

/* Light page, dark olive text. */
body {
    background-color: #F7F9F2;
    color: #1A2E05;
    font-family: Archivo, sans-serif;
    font-size: 1.05rem;
    line-height: 1.55;
}

/* Responsive images. */
img {
    display: block;
    max-width: 100%;
    height: auto;
}

/* Heavy display headings. */
h1,
h2,
h3 {
    font-family: "Archivo Black", sans-serif;
    font-weight: 400;
    line-height: 1.05;
}

/* Section titles. */
h2 {
    font-size: clamp(2rem, 4vw, 3rem);
}

/* Olive links. */
a {
    color: #3F6212;
    font-weight: 700;
}

/* Yellow-and-dark focus ring. */
a:focus-visible,
button:focus-visible,
.menu-check:focus-visible + .menu-icon {
    outline: 3px solid #1A2E05;
    box-shadow: 0px 0px 0px 6px #FACC15;
}

/* Muted intro paragraph. */
.lead {
    color: #4D5B3C;
    max-width: 36rem;
    margin: 10px 0px 26px 0px;
}

/* ----- Header (class) ----- */

/* Sticky dark header with a yellow-and-black hazard stripe at the bottom. */
.site-header {
    position: sticky;
    top: 0px;
    z-index: 20;
    background-color: #1A2E05;
    color: #FFFFFF;
    border-bottom: 6px solid #FACC15;
}

/* Logo and menu in a row. */
.header-inner {
    display: flex;
    flex-wrap: wrap;
    justify-content: space-between;
    align-items: center;
    padding: 12px 20px;
}

/* Logo text. */
.logo {
    font-family: "Archivo Black", sans-serif;
    font-size: 1.5rem;
    text-transform: uppercase;
}

/* Yellow shield. */
.logo i {
    color: #FACC15;
}

/* Small second line of the logo. */
.logo small {
    font-family: Archivo, sans-serif;
    font-size: 0.85rem;
    font-weight: 600;
    color: #D9E4C8;
}

/* Hidden menu checkbox (opacity keeps it keyboard reachable). */
.menu-check {
    position: absolute;
    opacity: 0;
    width: 1px;
    height: 1px;
}

/* Menu button. */
.menu-icon {
    background-color: #FACC15;
    color: #1A2E05;
    font-weight: 700;
    padding: 6px 14px;
    cursor: pointer;
}

/* Nav hidden on phones until opened. */
.site-nav {
    display: none;
    width: 100%;
}

/* Opened menu shows nav. */
.menu-check:checked ~ .site-nav {
    display: block;
}

/* No bullets. */
.site-nav ul {
    list-style: none;
    padding-top: 8px;
}

/* Phone nav links. */
.site-nav a {
    display: block;
    color: #FFFFFF;
    text-decoration: none;
    padding: 9px 0px;
    border-top: 1px solid #34501A;
}

/* Yellow on hover. */
.site-nav a:hover {
    color: #FACC15;
}

/* Concept notice. */
.concept-note {
    background-color: #3F6212;
    font-size: 0.85rem;
    text-align: center;
    padding: 4px 16px;
}

/* ----- Hero (class) ----- */

/* Photo background for the whole hero. */
.hero {
    background-image: url("images/hero.jpg");
    background-size: cover;
    background-position: center;
}

/* Dark olive panel over the photo, cut on a slant at desktop sizes. */
.hero-text {
    background-color: rgba(26, 46, 5, 0.92);
    color: #FFFFFF;
    padding: 48px 20px 52px 20px;
}

/* Headline. */
.hero h1 {
    font-size: clamp(2.4rem, 7vw, 4.4rem);
    text-transform: uppercase;
    margin-bottom: 16px;
}

/* Yellow second line. */
.hero h1 span {
    display: block;
    color: #FACC15;
}

/* Hero paragraph. */
.hero-text > p {
    max-width: 32rem;
    margin-bottom: 18px;
}

/* Badge list. */
.badges {
    list-style: none;
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-bottom: 26px;
}

/* One badge. */
.badges li {
    border: 1px solid #FACC15;
    padding: 4px 10px;
    font-size: 0.9rem;
    font-weight: 600;
}

/* Yellow badge icons. */
.badges i {
    color: #FACC15;
    margin-right: 4px;
}

/* Yellow button. */
.button,
button {
    display: inline-block;
    background-color: #FACC15;
    color: #1A2E05;
    border: none;
    padding: 14px 24px;
    font-family: "Archivo Black", sans-serif;
    font-size: 1rem;
    text-transform: uppercase;
    text-decoration: none;
    cursor: pointer;
}

/* Brighter on hover. */
.button:hover,
button:hover {
    background-color: #FDE047;
}

/* ----- Bug ID flip cards (class) ----- */

/* Section spacing. */
.bugs {
    padding: 56px 20px;
}

/* Cards wrap. */
.cards {
    display: flex;
    flex-wrap: wrap;
    gap: 16px;
}

/* One card. On phones it is a simple box. */
.card {
    flex: 1 1 240px;
}

/* Front and back share card styles. */
.front,
.back {
    padding: 22px;
}

/* Front: white with a thick olive border. */
.front {
    background-color: #FFFFFF;
    border: 3px solid #3F6212;
}

/* Big bug icon. */
.front i {
    font-size: 2.4rem;
    color: #3F6212;
    margin-bottom: 10px;
}

/* Card titles. */
.card h3 {
    font-size: 1.4rem;
    margin-bottom: 6px;
}

/* Back: dark with yellow heading. */
.back {
    background-color: #1A2E05;
    color: #FFFFFF;
}

/* Yellow heading on the back. */
.back h3 {
    color: #FACC15;
}

/* Yellow link on the back. */
.back a {
    display: inline-block;
    margin-top: 10px;
    color: #FACC15;
}

/* ----- Barrier diagram (ID and class) ----- */

/* Olive band. */
#barrier {
    display: flex;
    flex-direction: column;
    gap: 34px;
    background-color: #E6EDDA;
    padding: 56px 20px;
}

/* Diagram box: positioning parent for the ring and the house. */
.diagram {
    position: relative;
    width: 280px;
    height: 280px;
    margin: 0px auto;
}

/* The treated band: a dashed circle with a yellow glow inside. */
.ring {
    position: absolute;
    left: 0px;
    top: 0px;
    width: 100%;
    height: 100%;
    border: 4px dashed #3F6212;
    border-radius: 50%;
    background-color: rgba(250, 204, 21, 0.25);
}

/* The house sits in the middle of the ring. */
.house {
    position: absolute;
    left: 50%;
    top: 50%;
    transform: translate(-50%, -50%);
    width: 120px;
}

/* Roof drawn as a triangle with borders. */
.roof {
    display: block;
    width: 0px;
    height: 0px;
    margin: 0px auto;
    border-left: 70px solid transparent;
    border-right: 70px solid transparent;
    border-bottom: 50px solid #1A2E05;
    margin-left: -10px;
}

/* Walls with a door icon. */
.walls {
    display: block;
    height: 70px;
    background-color: #FFFFFF;
    border: 4px solid #1A2E05;
    border-top: none;
    text-align: center;
    padding-top: 22px;
    font-size: 1.6rem;
    color: #3F6212;
}

/* Label under the ring. */
.ring-label {
    position: absolute;
    left: 50%;
    bottom: -14px;
    transform: translateX(-50%);
    white-space: nowrap;
    background-color: #1A2E05;
    color: #FACC15;
    font-weight: 700;
    font-size: 0.85rem;
    padding: 3px 10px;
}

/* Space under the heading. */
.barrier-text h2 {
    margin-bottom: 12px;
}

/* Numbered barrier steps. */
.barrier-steps {
    margin: 16px 0px 20px 22px;
    font-weight: 600;
}

/* Space between steps. */
.barrier-steps li {
    padding: 3px 0px;
}

/* Photo with an olive frame. */
.barrier-text img {
    width: 100%;
    height: 240px;
    object-fit: cover;
    border: 5px solid #3F6212;
}

/* ----- Season bars (class) ----- */

/* Section spacing. */
.season {
    padding: 56px 20px;
}

/* The bar list. */
.bars {
    list-style: none;
}

/* One row: name above the bar on phones. */
.bars li {
    margin-bottom: 14px;
}

/* Pest name. */
.bar-name {
    display: block;
    font-weight: 700;
}

/* The bar itself, with the peak season written inside it. */
.bar {
    display: block;
    background-color: #3F6212;
    color: #FFFFFF;
    font-size: 0.9rem;
    font-weight: 600;
    padding: 4px 10px;
    white-space: nowrap;
}

/* Spring ants: a long bar. */
.bar-spring {
    width: 70%;
}

/* April termites: a short, sharp peak. */
.bar-april {
    width: 45%;
}

/* Summer mosquitoes: the longest. */
.bar-summer {
    width: 95%;
    background-color: #1A2E05;
}

/* Late summer wasps. */
.bar-late {
    width: 60%;
}

/* Fall and winter mice: long, in dark olive. */
.bar-fall {
    width: 85%;
    background-color: #1A2E05;
}

/* Two photos side by side. */
.season-photos {
    display: flex;
    gap: 12px;
    margin-top: 30px;
}

/* Each photo half the width. */
.season-photos img {
    width: 50%;
    height: 180px;
    object-fit: cover;
}

/* ----- Plans (class) ----- */

/* Dark band for plans. */
.plans {
    background-color: #1A2E05;
    color: #FFFFFF;
    padding: 56px 20px;
}

/* Light intro on dark. */
.plans .lead {
    color: #D9E4C8;
}

/* Plan cards stack on phones. */
.plan-row {
    display: flex;
    flex-direction: column;
    gap: 16px;
}

/* One plan card. */
.plan {
    position: relative;
    background-color: #FFFFFF;
    color: #1A2E05;
    padding: 24px;
}

/* Plan title. */
.plan h3 {
    font-size: 1.4rem;
}

/* Price line. */
.price {
    font-family: "Archivo Black", sans-serif;
    font-size: 2.2rem;
    margin: 8px 0px;
}

/* "/ visit" text after the price. */
.price span {
    font-family: Archivo, sans-serif;
    font-size: 1rem;
    color: #4D5B3C;
}

/* Plan features. */
.plan ul {
    list-style: none;
}

/* One feature with a check drawn as text before it. */
.plan li::before {
    content: "\2713  ";
    color: #3F6212;
    font-weight: 700;
}

/* The best plan has a yellow border. */
.plan-best {
    border: 5px solid #FACC15;
}

/* "Best value" flag pinned to the top right of its card. */
.flag {
    position: absolute;
    top: -14px;
    right: 16px;
    background-color: #FACC15;
    color: #1A2E05;
    font-weight: 700;
    font-size: 0.85rem;
    padding: 2px 10px;
}

/* ----- Quote form (class) ----- */

/* Section spacing. */
.quote {
    padding: 56px 20px;
}

/* Form card. */
.quote-form {
    background-color: #FFFFFF;
    border: 3px solid #1A2E05;
    padding: 22px;
    margin-top: 18px;
    max-width: 560px;
}

/* Labels. */
.quote-form label {
    display: block;
    font-weight: 700;
    margin-top: 12px;
}

/* Inputs and select. */
.quote-form input[type="text"],
.quote-form input[type="tel"],
.quote-form select {
    width: 100%;
    padding: 10px;
    margin-top: 4px;
    border: 2px solid #8A9A73;
    font-family: Archivo, sans-serif;
    font-size: 1rem;
    background-color: #FFFFFF;
}

/* Checkbox line. */
.check input {
    width: 18px;
    height: 18px;
    accent-color: #3F6212;
    margin-right: 6px;
}

/* Space above the button. */
.quote-form button {
    margin-top: 18px;
}

/* Phone line under the form. */
.quote-call {
    margin-top: 16px;
    font-weight: 600;
}

/* ----- Footer (class) ----- */

/* Dark footer with the hazard stripe on top. */
.site-footer {
    background-color: #1A2E05;
    color: #D9E4C8;
    border-top: 6px solid #FACC15;
    text-align: center;
    font-size: 0.85rem;
    padding: 22px 20px;
}

/* ----- Small tablets (576px and up) ----- */

@media (min-width: 576px) {

    /* Bars sit beside the pest name. */
    .bars li {
        display: flex;
        align-items: center;
        gap: 12px;
    }

    /* Fixed-width name column. */
    .bar-name {
        flex: 0 0 140px;
    }

    /* Taller season photos. */
    .season-photos img {
        height: 240px;
    }
}

/* ----- Tablets (768px and up) ----- */

@media (min-width: 768px) {

    /* Wider padding. */
    .bugs,
    #barrier,
    .season,
    .plans,
    .quote {
        padding-left: 40px;
        padding-right: 40px;
    }

    /* The hero panel only covers part of the photo, cut on a slant. */
    .hero-text {
        width: 72%;
        padding: 80px 18% 80px 40px;
        clip-path: polygon(0% 0%, 100% 0%, 80% 100%, 0% 100%);
    }

    /* Each card sets up 3D space and a fixed height for the flip. */
    .card {
        perspective: 1000px;
        height: 240px;
    }

    /* The inner box turns; both faces live inside it. */
    .card-inner {
        position: relative;
        width: 100%;
        height: 100%;
        transform-style: preserve-3d;
        transition: transform 0.6s;
    }

    /* Hover or keyboard focus inside the card flips it over. */
    .card:hover .card-inner,
    .card:focus-within .card-inner {
        transform: rotateY(180deg);
    }

    /* Both faces fill the card and hide their back side. */
    .front,
    .back {
        position: absolute;
        left: 0px;
        top: 0px;
        width: 100%;
        height: 100%;
        backface-visibility: hidden;
    }

    /* The back face starts already turned around. */
    .back {
        transform: rotateY(180deg);
    }

    /* Plans in a row. */
    .plan-row {
        flex-direction: row;
    }

    /* Equal plan widths. */
    .plan {
        flex: 1 1 30%;
    }
}

/* ----- Laptops (992px and up) ----- */

@media (min-width: 992px) {

    /* No Menu button on desktop. */
    .menu-icon {
        display: none;
    }

    /* Nav in the header row. */
    .site-nav {
        display: block;
        width: auto;
    }

    /* Links in a row. */
    .site-nav ul {
        display: flex;
        gap: 24px;
        padding-top: 0px;
    }

    /* No dividers on desktop. */
    .site-nav a {
        border-top: none;
        padding: 4px 0px;
    }

    /* Narrower slanted panel on big screens. */
    .hero-text {
        width: 60%;
        padding-top: 110px;
        padding-bottom: 110px;
    }

    /* Diagram and text side by side. */
    #barrier {
        flex-direction: row;
        align-items: center;
        gap: 60px;
    }

    /* Bigger diagram. */
    .diagram {
        flex: 0 0 340px;
        width: 340px;
        height: 340px;
    }

    /* Text takes the rest. */
    .barrier-text {
        flex: 1 1 auto;
    }

    /* Season bars and photos side by side. */
    .season {
        display: flex;
        flex-wrap: wrap;
        column-gap: 50px;
    }

    /* Heading and intro take a full row each. */
    .season h2,
    .season .lead {
        flex: 1 1 100%;
    }

    /* Bars column. */
    .bars {
        flex: 1 1 50%;
    }

    /* Photos column, stacked. */
    .season-photos {
        flex: 1 1 40%;
        flex-direction: column;
        margin-top: 0px;
    }

    /* Photos full width of their column. */
    .season-photos img {
        width: 100%;
        height: 170px;
    }

    /* Quote heading, form and phone in a row. */
    .quote {
        display: flex;
        align-items: center;
        gap: 40px;
    }

    /* Form keeps its own width. */
    .quote-form {
        flex: 1 1 560px;
        margin-top: 0px;
    }
}

/* ----- Wide screens (1200px and up) ----- */

@media (min-width: 1200px) {

    /* Center content at 1140px. */
    .header-inner,
    .bugs,
    #barrier,
    .season,
    .plans,
    .quote {
        padding-left: calc((100% - 1140px) / 2);
        padding-right: calc((100% - 1140px) / 2);
    }

    /* Hero text lines up with the page content. */
    .hero-text {
        padding-left: calc((100% - 1140px) / 2 + 0px);
        width: 62%;
    }

    /* Four cards in one row. */
    .card {
        flex: 1 1 22%;
    }
}
