/*
 * NestByNeighbor marketing site. The colors and fonts are the app's default "Harbor" theme
 * (resources/css/app.css in Fusani-Applications/nestbyneighbor): deep harbor blue with a marigold accent,
 * Bricolage Grotesque headings over Figtree.
 */

:root {
    --font-display: 'Bricolage Grotesque', ui-sans-serif, system-ui, sans-serif;
    --font-body: 'Figtree', ui-sans-serif, system-ui, sans-serif;

    --background: #f6f7f5;
    --foreground: #16232b;
    --card: #ffffff;
    --muted: #eef1ef;
    --muted-foreground: #52616b;
    --primary: #1d5b73;
    --primary-hover: #174a5e;
    --primary-foreground: #ffffff;
    --secondary: #e1eef2;
    --accent: #e8a33d;
    --highlight: #fbebcf;
    --border: #dce2e0;
    --input: #7f8f8a;
    --ring: #5c8ea1;
    --success: #287a47;
    --success-background: #e3f2e8;
    --error: #b42318;
    --error-background: #fdecea;
    --brand-panel: #1d5b73;
    --brand-panel-foreground: #ffffff;
    --shadow: 0 1px 2px rgb(22 35 43 / 6%), 0 8px 24px rgb(22 35 43 / 8%);

    --radius: 0.625rem;
    --container: 72rem;
    --gutter: 1.25rem;

    color-scheme: light;
}

@media (prefers-color-scheme: dark) {
    :root {
        --background: #0f1a20;
        --foreground: #e8eef0;
        --card: #16242c;
        --muted: #1c2a31;
        --muted-foreground: #9db0b8;
        --primary: #7cc3db;
        --primary-hover: #9dd3e6;
        --primary-foreground: #0b1a20;
        --secondary: #1c3540;
        --highlight: #3a2f1a;
        --border: #2a3a42;
        --input: #6b7f86;
        --ring: #7cc3db;
        --success: #6fcf97;
        --success-background: #143322;
        --error: #f59f95;
        --error-background: #3a1714;
        --brand-panel: #16384a;
        --brand-panel-foreground: #e8eef0;
        --shadow: 0 1px 2px rgb(0 0 0 / 30%), 0 8px 24px rgb(0 0 0 / 30%);

        color-scheme: dark;
    }
}

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

html {
    scroll-behavior: smooth;
    scroll-padding-top: 5rem;
}

@media (prefers-reduced-motion: reduce) {
    html {
        scroll-behavior: auto;
    }
}

body {
    margin: 0;
    background: var(--background);
    color: var(--foreground);
    font-family: var(--font-body);
    font-size: 1.0625rem;
    line-height: 1.6;
    -webkit-font-smoothing: antialiased;
}

img {
    display: block;
    max-width: 100%;
    height: auto;
}

h1,
h2,
h3 {
    font-family: var(--font-display);
    font-weight: 700;
    line-height: 1.15;
    letter-spacing: -0.01em;
    margin: 0 0 0.75rem;
}

h1 {
    font-size: clamp(2.1rem, 4.5vw, 3.25rem);
}

h2 {
    font-size: clamp(1.75rem, 3vw, 2.375rem);
}

h3 {
    font-size: 1.3rem;
}

p {
    margin: 0 0 1rem;
}

a {
    color: var(--primary);
    text-underline-offset: 0.15em;
}

a:hover {
    color: var(--primary-hover);
}

:focus-visible {
    outline: 3px solid var(--ring);
    outline-offset: 2px;
}

.container {
    width: 100%;
    max-width: var(--container);
    margin: 0 auto;
    padding: 0 var(--gutter);
}

.container--narrow {
    max-width: 46rem;
}

.skip-link {
    position: absolute;
    left: 1rem;
    top: -3rem;
    z-index: 100;
    padding: 0.5rem 1rem;
    background: var(--card);
    border-radius: var(--radius);
}

.skip-link:focus {
    top: 1rem;
}

/* Buttons */

.button {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    padding: 0.75rem 1.4rem;
    border: 2px solid var(--primary);
    border-radius: var(--radius);
    background: var(--primary);
    color: var(--primary-foreground);
    font: 600 1rem/1.2 var(--font-body);
    text-decoration: none;
    white-space: nowrap;
    cursor: pointer;
    transition: background-color 0.15s, border-color 0.15s, color 0.15s;
}

.button:hover {
    background: var(--primary-hover);
    border-color: var(--primary-hover);
    color: var(--primary-foreground);
}

.button:disabled {
    opacity: 0.6;
    cursor: not-allowed;
}

.button--small {
    padding: 0.5rem 1rem;
    font-size: 0.95rem;
}

.button--outline {
    background: transparent;
    color: var(--primary);
}

.button--outline:hover {
    background: var(--secondary);
    color: var(--primary);
}

.button--light {
    background: var(--brand-panel-foreground);
    border-color: var(--brand-panel-foreground);
    color: var(--brand-panel);
}

.button--light:hover {
    background: var(--highlight);
    border-color: var(--highlight);
    color: var(--foreground);
}

.button--outline-light {
    background: transparent;
    border-color: var(--brand-panel-foreground);
    color: var(--brand-panel-foreground);
}

.button--outline-light:hover {
    background: rgb(255 255 255 / 12%);
    border-color: var(--brand-panel-foreground);
    color: var(--brand-panel-foreground);
}

/* Header */

.site-header {
    position: sticky;
    top: 0;
    z-index: 50;
    background: color-mix(in srgb, var(--background) 90%, transparent);
    backdrop-filter: blur(8px);
    border-bottom: 1px solid var(--border);
}

.site-header__inner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1rem;
    min-height: 4rem;
}

.brand {
    display: inline-flex;
    align-items: center;
    gap: 0.6rem;
    color: var(--foreground);
    text-decoration: none;
}

.brand:hover {
    color: var(--foreground);
}

.brand__name {
    font-family: var(--font-display);
    font-weight: 700;
    font-size: 1.25rem;
}

.site-nav {
    display: flex;
    align-items: center;
    gap: 1.5rem;
}

.site-nav a:not(.button) {
    color: var(--foreground);
    font-weight: 500;
    text-decoration: none;
}

.site-nav a:not(.button):hover {
    color: var(--primary);
}

@media (max-width: 52rem) {
    .site-nav a:not(.button) {
        display: none;
    }
}

/* Sections */

.section {
    padding: clamp(3.5rem, 8vw, 6rem) 0;
}

.section--tinted {
    background: var(--muted);
}

.section--brand {
    background: var(--brand-panel);
    color: var(--brand-panel-foreground);
}

.section__title {
    margin-bottom: 1rem;
}

.section__intro {
    max-width: 44rem;
    margin-bottom: 2.5rem;
    color: var(--muted-foreground);
    font-size: 1.15rem;
}

.section--brand .section__intro {
    color: inherit;
    opacity: 0.9;
}

.eyebrow {
    margin-bottom: 0.5rem;
    color: var(--primary);
    font-size: 0.85rem;
    font-weight: 600;
    letter-spacing: 0.06em;
    text-transform: uppercase;
}

.lead {
    font-size: 1.2rem;
    color: var(--muted-foreground);
}

.card {
    padding: 1.75rem;
    background: var(--card);
    border: 1px solid var(--border);
    border-radius: calc(var(--radius) * 1.5);
    box-shadow: var(--shadow);
}

.card__note {
    margin: 1rem 0 0;
    color: var(--muted-foreground);
    font-size: 0.95rem;
}

.screenshot {
    margin: 0;
    overflow: hidden;
    background: var(--card);
    border: 1px solid var(--border);
    border-radius: calc(var(--radius) * 1.5);
    box-shadow: var(--shadow);
}

/* Hero */

.hero {
    padding: clamp(3rem, 7vw, 5.5rem) 0 clamp(3.5rem, 8vw, 6rem);
    background:
        radial-gradient(60rem 30rem at 90% -10%, color-mix(in srgb, var(--accent) 18%, transparent), transparent 70%),
        var(--background);
}

.hero__inner {
    display: grid;
    grid-template-columns: minmax(0, 1fr) minmax(0, 1.1fr);
    align-items: center;
    gap: clamp(2rem, 5vw, 4rem);
}

.hero__actions {
    display: flex;
    flex-wrap: wrap;
    gap: 0.75rem;
    margin-top: 1.75rem;
}

.hero__shot {
    transform: perspective(1600px) rotateY(-4deg);
}

@media (max-width: 56rem) {
    .hero__inner {
        grid-template-columns: minmax(0, 1fr);
    }

    .hero__shot {
        transform: none;
    }
}

/* How it works */

.steps {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(14rem, 1fr));
    gap: 1.25rem;
    margin: 0;
    padding: 0;
    list-style: none;
}

.step {
    padding: 1.5rem;
    background: var(--card);
    border: 1px solid var(--border);
    border-radius: calc(var(--radius) * 1.5);
}

.step p {
    margin: 0;
    color: var(--muted-foreground);
}

.step__number {
    display: inline-grid;
    place-items: center;
    width: 2.25rem;
    height: 2.25rem;
    margin-bottom: 1rem;
    background: var(--highlight);
    border-radius: 999px;
    color: var(--foreground);
    font-family: var(--font-display);
    font-weight: 700;
}

/* Features */

.feature {
    display: grid;
    grid-template-columns: minmax(0, 1fr) minmax(0, 1.25fr);
    align-items: center;
    gap: clamp(2rem, 5vw, 4rem);
    padding: 2.5rem 0;
}

.feature--flipped .feature__text {
    order: 2;
}

.feature__text p:last-child {
    color: var(--muted-foreground);
}

@media (max-width: 52rem) {
    .feature {
        grid-template-columns: minmax(0, 1fr);
        padding: 1.5rem 0;
    }

    .feature--flipped .feature__text {
        order: 0;
    }
}

/* Who it's for */

.columns {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(18rem, 1fr));
    gap: 1.5rem;
}

.checklist {
    margin: 0;
    padding: 0;
    list-style: none;
}

.checklist li {
    position: relative;
    padding: 0.35rem 0 0.35rem 2rem;
}

.checklist li::before {
    content: '';
    position: absolute;
    left: 0.2rem;
    top: 0.75rem;
    width: 1rem;
    height: 0.55rem;
    border-left: 3px solid var(--success);
    border-bottom: 3px solid var(--success);
    transform: rotate(-45deg);
}

.checklist--muted li {
    color: var(--muted-foreground);
}

.checklist--muted li::before {
    top: 1rem;
    height: 0;
    border-left: 0;
    border-bottom-color: var(--muted-foreground);
    transform: none;
}

/* Story */

.story {
    display: grid;
    grid-template-columns: minmax(0, 1.2fr) minmax(0, 1fr);
    gap: clamp(2rem, 5vw, 4rem);
    align-items: start;
}

.story__points {
    display: grid;
    gap: 1rem;
    margin: 0;
    padding: 0;
    list-style: none;
}

.story__points li {
    padding: 1rem 1.25rem;
    background: var(--card);
    border-left: 4px solid var(--accent);
    border-radius: var(--radius);
    box-shadow: var(--shadow);
}

.story__points strong {
    display: block;
    font-family: var(--font-display);
}

@media (max-width: 52rem) {
    .story {
        grid-template-columns: minmax(0, 1fr);
    }
}

/* Demo */

.roles {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(16rem, 1fr));
    gap: 1.25rem;
}

.role {
    display: flex;
    flex-direction: column;
    padding: 1.5rem;
    background: rgb(255 255 255 / 8%);
    border: 1px solid rgb(255 255 255 / 20%);
    border-radius: calc(var(--radius) * 1.5);
}

.role p {
    flex: 1;
    opacity: 0.9;
}

.role .button {
    align-self: flex-start;
}

.public-forms {
    margin-top: 3rem;
    padding-top: 2.5rem;
    border-top: 1px solid rgb(255 255 255 / 20%);
}

.public-forms__links {
    display: flex;
    flex-wrap: wrap;
    gap: 0.75rem;
    margin-bottom: 1rem;
}

.public-forms__note {
    margin: 0;
    opacity: 0.85;
    font-size: 0.95rem;
}

/* Pricing */

.pricing {
    display: grid;
    grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
    gap: clamp(2rem, 5vw, 4rem);
    align-items: center;
}

@media (max-width: 52rem) {
    .pricing {
        grid-template-columns: minmax(0, 1fr);
    }
}

/* Contact */

.contact {
    display: grid;
    grid-template-columns: minmax(0, 0.9fr) minmax(0, 1.1fr);
    gap: clamp(2rem, 5vw, 4rem);
    align-items: start;
}

.contact__intro p {
    color: var(--muted-foreground);
    font-size: 1.15rem;
}

@media (max-width: 52rem) {
    .contact {
        grid-template-columns: minmax(0, 1fr);
    }
}

.field-row {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(13rem, 1fr));
    gap: 0 1rem;
}

.field {
    margin-bottom: 1.1rem;
}

.field label {
    display: block;
    margin-bottom: 0.35rem;
    font-weight: 600;
}

.field__optional {
    color: var(--muted-foreground);
    font-weight: 400;
}

.field input,
.field textarea {
    width: 100%;
    padding: 0.7rem 0.85rem;
    background: var(--card);
    border: 1px solid var(--input);
    border-radius: var(--radius);
    color: var(--foreground);
    font: inherit;
}

.field textarea {
    resize: vertical;
}

.field input:focus-visible,
.field textarea:focus-visible {
    outline: 3px solid var(--ring);
    outline-offset: 0;
    border-color: var(--ring);
}

#contact-form .form-extra {
    display: none;
}

.recaptcha-note {
    margin: 1rem 0 0;
    color: var(--muted-foreground);
    font-size: 0.8rem;
}

/* reCAPTCHA's notice above stands in for its badge, which Google allows. */
.grecaptcha-badge {
    visibility: hidden;
}

.alert {
    margin-bottom: 1.25rem;
    padding: 0.85rem 1rem;
    border-radius: var(--radius);
    font-weight: 500;
}

.alert--success {
    background: var(--success-background);
    color: var(--success);
}

.alert--error {
    background: var(--error-background);
    color: var(--error);
}

.alert--info {
    background: var(--secondary);
}

.spinner {
    width: 1rem;
    height: 1rem;
    border: 2px solid currentcolor;
    border-right-color: transparent;
    border-radius: 999px;
    animation: spin 0.7s linear infinite;
}

@keyframes spin {
    to {
        transform: rotate(360deg);
    }
}

/* Privacy and other text pages */

.prose h1 {
    margin-bottom: 0.5rem;
}

.prose h2 {
    margin-top: 2.25rem;
    font-size: 1.5rem;
}

.prose__updated {
    color: var(--muted-foreground);
}

/* Footer */

.site-footer {
    padding: 3rem 0 2rem;
    border-top: 1px solid var(--border);
}

.site-footer__inner {
    display: flex;
    flex-wrap: wrap;
    justify-content: space-between;
    gap: 2rem;
}

.site-footer__tagline {
    margin: 0.75rem 0 0;
    color: var(--muted-foreground);
}

.site-footer__links {
    display: flex;
    flex-wrap: wrap;
    gap: 1.5rem;
}

.site-footer__links a {
    color: var(--foreground);
    text-decoration: none;
}

.site-footer__links a:hover {
    color: var(--primary);
}

.site-footer__legal {
    margin-top: 2rem;
    color: var(--muted-foreground);
    font-size: 0.9rem;
}

.site-footer__legal a {
    color: inherit;
}
