html {
    box-sizing: border-box;
    font-family: Arial, Helvetica, sans-serif;
}

*,
*::before,
*::after {
    box-sizing: inherit;
}

body {
    margin: 0;
    background: #e9eef5;
    color: #222;
    line-height: 1.6;
}

.wrapper {
    width: min(92%, 1024px);
    margin: 2rem auto;
    padding: 1.5rem;
    display: grid;
    gap: 1.5rem;
    background: #ffffff;
    border-radius: 16px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.12);
}

header,
main,
aside,
nav,
footer {
    background: #ffffff;
}

header h1,
main h2,
aside h2,
nav h2 {
    margin-top: 0;
    margin-bottom: 0.75rem;
    color: #1f3c88;
}

nav,
footer {
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
}

nav a,
footer a {
    display: inline-block;
    color: #1f3c88;
    background: #f4f7fb;
    line-height: 1.4;
    border: 1px solid #d7e0ec;
    border-radius: 10px;
    padding: 0.75rem 1rem;
    text-decoration: none;
    transition: background-color 0.2s ease, transform 0.2s ease, box-shadow 0.2s ease;
}

nav a:hover,
footer a:hover {
    background: #e8f0fe;
    box-shadow: 0 6px 14px rgba(0, 0, 0, 0.12);
    transform: translateY(-2px);
}

a:link {
    color: #1f3c88;
}

a:visited {
    color: #5a3d8b;
}

a:hover {
    color: #c0392b;
}

p {
    max-width: 64ch;
    margin-top: 0;
}

.intro {
    padding: 1rem 1.25rem;
    background: #e8f0fe;
    border-radius: 12px;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.10);
}

ul,
ol {
    padding-left: 1.5rem;
    margin: 0;
}

ol {
    list-style-type: decimal-leading-zero;
}

li + li {
    margin-top: 0.4rem;
}

form {
    font-size: 1rem;
    font-family: inherit;
    max-width: 64ch;
}

form * {
    font-size: inherit;
    font-family: inherit;
    margin: 0;
    align-self: baseline;
}

form fieldset {
    border: none;
    padding: 0;
    margin: 0;
}

form fieldset legend {
    padding: 0;
    margin-bottom: 0.5rem;
    font-weight: bold;
}

form ol {
    list-style-type: none;
    padding: 0;
}

form ol li {
    margin-bottom: 1rem;
    padding: 0.75rem;
    background: #f8fafc;
    border: 1px solid #e1e8f0;
    border-radius: 10px;
}

form ol li label:not(:empty) {
    display: block;
    margin: 0.25rem 0 0.4rem;
    font-weight: 600;
}

form ol li input:not([type="submit"], [type="reset"], [type="button"], [type="image"], [type="radio"], [type="checkbox"]),
form ol li select,
form ol li textarea {
    width: 100%;
    padding: 0.65rem 0.75rem;
    border: 1px solid #cfd8e3;
    border-radius: 8px;
    background: #ffffff;
}

form ol li input[type="color"] {
    height: 3rem;
    padding: 0.2rem;
}

form fieldset:has([type="radio"], [type="checkbox"]) {
    display: grid;
    grid-template-columns: auto 1fr;
    gap: 0.35rem 0.5rem;
}

form fieldset:has([type="radio"], [type="checkbox"]) label.error {
    grid-column: 1 / -1;
}

form fieldset:has([type="radio"], [type="checkbox"]) label {
    padding-left: 0.25rem;
}

form .error-parent {
    background-color: #ffe0db;
    border-radius: 8px;
}

input:focus,
select:focus,
textarea:focus {
    outline: 2px solid #9bbcf7;
    outline-offset: 2px;
}

footer {
    border-top: 1px solid #dbe3ec;
    padding-top: 1rem;
}

/*-------------------
 FINAL PROJECT STYLING 
 ---------------------*/


.final-project-feature {
    max-width: 1100px;
    margin: 40px auto;
    padding: 20px;
}

.final-project-card {
    position: relative;
    overflow: hidden;
    padding: 40px;
    border-radius: 18px;
    background:
        linear-gradient(135deg, rgba(17, 24, 39, 0.95), rgba(63, 29, 56, 0.95)),
        radial-gradient(circle at top right, rgba(239, 68, 68, 0.35), transparent 35%);
    color: #ffffff;
    border: 1px solid rgba(239, 68, 68, 0.45);
    box-shadow: 0 14px 30px rgba(0, 0, 0, 0.35);
}

.final-project-card::before {
    content: "FINAL";
    position: absolute;
    right: -20px;
    bottom: -20px;
    font-size: 6rem;
    font-weight: 900;
    color: rgba(255, 255, 255, 0.04);
    letter-spacing: 4px;
}

.final-project-card .eyebrow {
    margin: 0 0 10px;
    color: #fca5a5;
    font-weight: bold;
    text-transform: uppercase;
    letter-spacing: 2px;
}

.final-project-card h2 {
    margin: 0 0 12px;
    font-size: 2.4rem;
}

.final-project-card p {
    max-width: 650px;
    line-height: 1.6;
    color: #e5e7eb;
}

.final-project-btn {
    display: inline-block;
    margin-top: 18px;
    padding: 13px 22px;
    border-radius: 999px;
    background: #ef4444;
    color: #ffffff;
    font-weight: bold;
    text-decoration: none;
    border: 2px solid transparent;
    box-shadow: 0 8px 20px rgba(239, 68, 68, 0.35);
    transition:
        background-color 0.2s ease,
        color 0.2s ease,
        transform 0.2s ease,
        border-color 0.2s ease,
        box-shadow 0.2s ease;
}

.final-project-btn:hover,
.final-project-btn:focus {
    background: #ffffff;
    color: #111827;
    border-color: #ef4444;
    transform: translateY(-3px);
    box-shadow: 0 12px 24px rgba(255, 255, 255, 0.18);
}

.final-project-btn:focus-visible {
    outline: 3px solid #ffffff;
    outline-offset: 3px;
}

/*-----------------
END OF FINAL STYLING
--------------------*/

@media screen and (max-width: 600px) {
    .final-project-card {
        padding: 28px;
    }

    .final-project-card h2 {
        font-size: 1.8rem;
    }

    .final-project-card::before {
        font-size: 4rem;
    }
}


@media screen and (min-width: 768px) {
    nav,
    footer {
        flex-direction: row;
        flex-wrap: wrap;
        align-items: center;
    }

    nav :first-child,
    footer :first-child {
        margin-right: auto;
    }

    .columns {
        display: grid;
        gap: 1.5rem;
        grid-template-columns: 7fr 3fr;
        align-items: start;
    }
}