/*
  organizedprojects.com
  Brand pastel red #f4a7a3 and Instrument Sans, shared with the app. Pastel is too
  light for white text, so anything on the brand is deep red --brand-ink (6.75:1);
  red text is --brand-text (#b0322a, 6.3:1 on white), and the bare logo mark on
  light surfaces is #d2564c (3.75:1+), since the pastel there is only 1.9:1.
  Neutrals are warm so they sit with the red.
  The crew colors are the app's own: they mark people on the schedule and the board.
*/
:root {
    --brand: #f4a7a3;
    --brand-hover: #ec928c;
    --brand-ink: #5c1a16;
    --brand-text: #b0322a;
    --logo: var(--brand);
    --logo-mark: #d2564c;
    --ink: #1f1a1a;
    --ink-soft: #5a5150;
    --paper: #ffffff;
    --blueprint: #faf5f4;
    --grid: #ecdedc;
    --grid-strong: #dcc9c6;

    --crew-0: #2c4ed3;
    --crew-1: #0e8a7b;
    --crew-2: #b4387a;
    --crew-3: #c26a12;

    --font: 'Instrument Sans', ui-sans-serif, system-ui, -apple-system, 'Segoe UI', sans-serif;
    --measure: 36rem;
    --gutter: clamp(1rem, 4vw, 2.5rem);
    --hours: 10;
}

@media (prefers-color-scheme: dark) {
    :root {
        --brand-text: var(--brand);
        --logo-mark: var(--brand);
        --ink: #f2ecec;
        --ink-soft: #b3a9a8;
        --paper: #171213;
        --blueprint: #1e1819;
        --grid: #322828;
        --grid-strong: #403434;
        --crew-0: #6f8cf0;
        --crew-1: #3fbfae;
        --crew-2: #e07ab0;
        --crew-3: #e8994a;
    }
}

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

html {
    -webkit-text-size-adjust: 100%;
    scroll-behavior: smooth;
}

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

h1,
h2,
h3 {
    margin: 0;
    line-height: 1.1;
    letter-spacing: -0.02em;
    text-wrap: balance;
}

p {
    margin: 0;
    text-wrap: pretty;
}

a {
    color: var(--brand-text);
}

:focus-visible {
    outline: 3px solid var(--brand-text);
    outline-offset: 3px;
    border-radius: 4px;
}

.wrap {
    width: 100%;
    max-width: 72rem;
    margin-inline: auto;
    padding-inline: var(--gutter);
}

.skip {
    position: absolute;
    left: 1rem;
    top: -4rem;
    padding: 0.5rem 1rem;
    background: var(--brand);
    color: var(--brand-ink);
    z-index: 10;
}

.skip:focus {
    top: 1rem;
}

/* Header */

.masthead {
    border-bottom: 1px solid var(--grid);
}

.masthead__inner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1.5rem;
    min-height: 4.25rem;
}

.brand {
    display: inline-flex;
    align-items: center;
    gap: 0.625rem;
    font-weight: 600;
    color: var(--ink);
    text-decoration: none;
    letter-spacing: -0.01em;
    white-space: nowrap;
}

.brand svg {
    width: 2rem;
    height: 2rem;
    color: var(--logo-mark);
}

.brand__wordmark {
    display: inline-grid;
    gap: 0.125rem;
    font-family: 'Big Shoulders Display', var(--font);
    font-weight: 800;
    line-height: 1;
    text-transform: uppercase;
}

/* Spread "Projects" so both ends line up with "Organized" */
.brand__stretch {
    display: flex;
    justify-content: space-between;
}

.nav {
    display: flex;
    align-items: center;
    gap: 1.5rem;
    font-size: 0.9375rem;
}

.nav a:not(.button) {
    color: var(--ink-soft);
    text-decoration: none;
}

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

@media (max-width: 52rem) {
    .nav a[href*='#'] {
        display: none;
    }
}

@media (max-width: 30rem) {
    /* Phones: just the account button. Sign in and Plans are in the footer and the page body. */
    .nav a[href='/app/login'],
    .nav a[href='/plans'] {
        display: none;
    }

    .nav .button--small {
        padding: 0 0.75rem;
        font-size: 0.875rem;
    }
}

/* Buttons */

.button {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 3rem;
    padding: 0 1.375rem;
    border-radius: 0.5rem;
    background: var(--brand);
    color: var(--brand-ink);
    font-weight: 600;
    text-decoration: none;
    white-space: nowrap;
}

.button:hover {
    background: var(--brand-hover);
}

.button--small {
    min-height: 2.5rem;
    padding: 0 1rem;
    font-size: 0.9375rem;
}

/* On a pastel band, the button flips to deep red so it still stands out. */
.button--ink {
    background: var(--brand-ink);
    color: #fff;
}

.button--ink:hover {
    background: #451310;
}

.link {
    font-weight: 500;
    text-underline-offset: 0.2em;
}

/* Hero */

.hero {
    padding-block: clamp(3rem, 8vw, 6rem) clamp(3rem, 7vw, 5rem);
    background:
        linear-gradient(var(--grid) 1px, transparent 1px) 0 0 / 100% 2rem,
        var(--blueprint);
    background-blend-mode: normal;
    border-bottom: 1px solid var(--grid);
}

.hero > .wrap:first-child {
    display: grid;
    gap: 1.75rem;
    margin-bottom: clamp(2.5rem, 6vw, 4rem);
}

@media (min-width: 60rem) {
    .hero > .wrap:first-child {
        grid-template-columns: 1.15fr 1fr;
        align-items: end;
        gap: 4rem;
    }
}

.hero__title {
    font-size: clamp(2.5rem, 6.4vw, 4.75rem);
    font-weight: 600;
    letter-spacing: -0.035em;
    line-height: 1;
}

.hero__lede {
    max-width: var(--measure);
}

.hero__lede p {
    font-size: 1.1875rem;
    color: var(--ink-soft);
}

.hero__actions {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 1rem 1.5rem;
    margin-top: 1.75rem;
}

/* The board */

.board {
    margin: 0;
    background: var(--paper);
    border: 1px solid var(--grid-strong);
    border-radius: 0.75rem;
    box-shadow: 0 1px 0 var(--grid), 0 24px 48px -28px rgb(92 26 22 / 0.22);
    overflow: hidden;
}

.board__head {
    display: flex;
    justify-content: space-between;
    align-items: baseline;
    padding: 0.875rem 1.25rem;
    border-bottom: 1px solid var(--grid);
    font-size: 0.9375rem;
}

.board__day {
    font-weight: 600;
}

.board__count {
    color: var(--ink-soft);
}

.board__count b {
    color: var(--ink);
    font-variant-numeric: tabular-nums;
}

.board__grid {
    --label: 6.5rem;
    position: relative;
    padding: 0 1.25rem 1rem;
}

.board__hours {
    position: relative;
    height: 2.25rem;
    margin-left: var(--label);
    font-size: 0.8125rem;
    color: var(--ink-soft);
    font-variant-numeric: tabular-nums;
}

.board__hours span {
    position: absolute;
    bottom: 0.5rem;
    left: calc(var(--at) / var(--hours) * 100%);
    transform: translateX(-50%);
    white-space: nowrap;
}

.row {
    display: grid;
    grid-template-columns: var(--label) 1fr;
    align-items: center;
    min-height: 3.75rem;
    border-top: 1px solid var(--grid);
}

.row__who {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-weight: 500;
    font-size: 0.9375rem;
}

.row__who i {
    width: 0.625rem;
    height: 0.625rem;
    border-radius: 50%;
    background: var(--crew);
}

.row__track {
    position: relative;
    height: 2.75rem;
    background: repeating-linear-gradient(
        to right,
        transparent 0,
        transparent calc(100% / var(--hours) - 1px),
        var(--grid) calc(100% / var(--hours) - 1px),
        var(--grid) calc(100% / var(--hours))
    );
}

.job {
    position: absolute;
    top: 0.25rem;
    bottom: 0.25rem;
    left: calc(var(--from) / var(--hours) * 100%);
    width: calc((var(--to) - var(--from)) / var(--hours) * 100% - 3px);
    display: flex;
    flex-direction: column;
    justify-content: center;
    padding: 0 0.625rem;
    border-left: 3px solid var(--crew);
    border-radius: 0.3125rem;
    background: color-mix(in oklab, var(--crew) 13%, var(--paper));
    font-size: 0.8125rem;
    font-weight: 600;
    line-height: 1.2;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.job small {
    font-weight: 400;
    color: var(--ink-soft);
    font-size: 0.75rem;
}

.job--travel {
    border-left: 0;
    background: repeating-linear-gradient(
        135deg,
        color-mix(in oklab, var(--crew) 22%, var(--paper)) 0 4px,
        transparent 4px 8px
    );
}

.job--off {
    border-left-color: var(--grid-strong);
    background: repeating-linear-gradient(135deg, var(--blueprint) 0 6px, var(--paper) 6px 12px);
    color: var(--ink-soft);
    font-weight: 500;
}

.board__now {
    position: absolute;
    top: 2.25rem;
    bottom: 1rem;
    left: calc(1.25rem + var(--label) + (100% - 2.5rem - var(--label)) * var(--at) / var(--hours));
    width: 2px;
    background: var(--brand-text);
    pointer-events: none;
}

.board__now span {
    position: absolute;
    top: -1.75rem;
    left: 50%;
    transform: translateX(-50%);
    padding: 0.0625rem 0.4375rem;
    border-radius: 999px;
    background: var(--brand);
    color: var(--brand-ink);
    font-size: 0.6875rem;
    font-weight: 600;
}

.board figcaption {
    padding: 0.875rem 1.25rem;
    border-top: 1px solid var(--grid);
    font-size: 0.875rem;
    color: var(--ink-soft);
}

/* The one moment: an unassigned job lands on Priya's row. */
.board.is-live .job--drop {
    animation: drop 700ms cubic-bezier(0.2, 0.9, 0.25, 1.15) 900ms both;
}

@keyframes drop {
    from {
        transform: translateY(-5.5rem) rotate(-2deg);
        opacity: 0;
        box-shadow: 0 18px 30px -12px rgb(14 138 123 / 0.5);
    }
    70% {
        opacity: 1;
    }
    to {
        transform: none;
        opacity: 1;
        box-shadow: none;
    }
}

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

    .board.is-live .job--drop {
        animation: none;
    }
}

/* Narrow screens: the board scrolls sideways inside itself rather than crushing the jobs. */
@media (max-width: 44rem) {
    .board__grid {
        --label: 5rem;
        overflow-x: auto;
    }

    .board__grid > * {
        min-width: 38rem;
    }

    .board__now {
        display: none;
    }
}

/* Sections */

.features,
.flow,
.roles {
    padding-block: clamp(3.5rem, 8vw, 6rem);
}

.features h2,
.flow h2,
.roles h2 {
    font-size: clamp(1.75rem, 3.4vw, 2.5rem);
    font-weight: 600;
}

.section-lede {
    max-width: var(--measure);
    margin-top: 0.875rem;
    font-size: 1.1875rem;
    color: var(--ink-soft);
}

.feature-list {
    display: grid;
    gap: 2.25rem 3rem;
    margin: 3rem 0 0;
}

@media (min-width: 46rem) {
    .feature-list {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (min-width: 66rem) {
    .feature-list {
        grid-template-columns: repeat(3, 1fr);
    }
}

.feature-list div {
    padding-top: 1rem;
    border-top: 2px solid var(--ink);
}

.feature-list dt {
    font-weight: 600;
    font-size: 1.125rem;
    letter-spacing: -0.01em;
}

.feature-list dd {
    margin: 0.5rem 0 0;
    color: var(--ink-soft);
}

.flow {
    background: var(--blueprint);
    border-block: 1px solid var(--grid);
}

.steps {
    display: grid;
    gap: 2rem;
    margin: 3rem 0 0;
    padding: 0;
    list-style: none;
    counter-reset: step;
}

@media (min-width: 52rem) {
    .steps {
        grid-template-columns: repeat(4, 1fr);
        gap: 0;
    }
}

.steps li {
    position: relative;
    padding: 2.75rem 1.5rem 0 0;
    counter-increment: step;
}

/* The steps are a real sequence, so they read as stops along one line. */
.steps li::before {
    content: counter(step);
    position: absolute;
    top: 0;
    left: 0;
    display: grid;
    place-items: center;
    width: 2rem;
    height: 2rem;
    border-radius: 50%;
    background: var(--brand);
    color: var(--brand-ink);
    font-size: 0.9375rem;
    font-weight: 600;
    z-index: 1;
}

@media (min-width: 52rem) {
    .steps li::after {
        content: '';
        position: absolute;
        top: 1rem;
        left: 0;
        right: 0;
        height: 2px;
        background: var(--grid-strong);
    }

    .steps li:last-child::after {
        right: auto;
        width: 2rem;
    }
}

.steps h3 {
    font-size: 1.125rem;
    font-weight: 600;
    letter-spacing: -0.01em;
}

.steps p {
    margin-top: 0.375rem;
    color: var(--ink-soft);
}

.roles__inner {
    display: grid;
    gap: 3rem;
}

@media (min-width: 52rem) {
    .roles__inner {
        grid-template-columns: 1.4fr 1fr;
        gap: 5rem;
    }
}

.roles p {
    max-width: var(--measure);
    margin-top: 1rem;
    color: var(--ink-soft);
}

.roles__inner > div:last-child h2 {
    font-size: 1.375rem;
}

.next {
    margin: 1rem 0 0;
    padding: 0;
    list-style: none;
}

.next li {
    padding: 0.75rem 0;
    border-bottom: 1px solid var(--grid);
    color: var(--ink-soft);
}

.next li:first-child {
    border-top: 1px solid var(--grid);
}

/* Call to action */

.cta {
    background: var(--brand);
    color: var(--brand-ink);
}

.cta__inner {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: space-between;
    gap: 1.5rem;
    padding-block: clamp(3rem, 7vw, 4.5rem);
}

.cta h2 {
    font-size: clamp(1.75rem, 3.6vw, 2.75rem);
    font-weight: 600;
    max-width: 20ch;
}

/* Footer */

.footer {
    font-size: 0.9375rem;
    color: var(--ink-soft);
}

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

.footer nav {
    display: flex;
    gap: 1.5rem;
}

.footer a {
    color: var(--ink-soft);
}

/* 404 */

.missing {
    min-height: 60vh;
    display: grid;
    align-content: center;
    gap: 1rem;
    padding-block: 5rem;
}

.missing h1 {
    font-size: clamp(2rem, 5vw, 3.25rem);
    font-weight: 600;
}

.missing p {
    color: var(--ink-soft);
    max-width: var(--measure);
}

/* Plans */

.nav a[aria-current='page'] {
    color: var(--ink);
    font-weight: 600;
}

.plans-hero {
    padding-block: clamp(3rem, 7vw, 5rem) 0;
}

.plans-hero h1 {
    font-size: clamp(2.25rem, 5vw, 3.5rem);
    font-weight: 600;
    letter-spacing: -0.03em;
    max-width: 18ch;
}

.plans {
    padding-block: clamp(2.5rem, 5vw, 3.5rem) clamp(3.5rem, 8vw, 6rem);
}

/* Columns divided by rules rather than boxed as cards; the middle plan sits on a blush panel. */
.plans__grid {
    display: grid;
    gap: 2.5rem;
}

@media (min-width: 56rem) {
    .plans__grid {
        grid-template-columns: repeat(3, 1fr);
        gap: 0;
    }
}

.plan {
    display: flex;
    flex-direction: column;
    padding: 1.75rem 0 0;
    border-top: 2px solid var(--ink);
}

@media (min-width: 56rem) {
    .plan {
        padding: 1.75rem 2rem 2rem;
    }

    .plan + .plan {
        border-left: 1px solid var(--grid);
    }
}

.plan--featured {
    border-top: 6px solid var(--brand);
    background: var(--blueprint);
    /* The thicker top rule would push the content down; take it back out of the padding. */
    padding: calc(1.75rem - 4px) 1.5rem 1.75rem;
}

@media (min-width: 56rem) {
    .plan--featured {
        padding: calc(1.75rem - 4px) 2rem 2rem;
    }
}

.plan h2 {
    font-size: 1.5rem;
    font-weight: 600;
}

.plan__fit {
    margin-top: 0.5rem;
    color: var(--ink-soft);
    min-height: 3.2em;
}

.plan__price {
    margin-top: 1.5rem;
    font-size: 2.75rem;
    font-weight: 600;
    letter-spacing: -0.03em;
    line-height: 1;
    font-variant-numeric: tabular-nums;
}

.plan__price small {
    font-size: 1rem;
    font-weight: 500;
    letter-spacing: 0;
    color: var(--ink-soft);
}

.plan__limit {
    margin-top: 0.625rem;
    font-weight: 500;
}

.plan__cta {
    margin-top: 1.5rem;
    align-self: flex-start;
}

.plan__list {
    margin: 1.75rem 0 0;
    padding: 0;
    list-style: none;
}

.plan__list li {
    position: relative;
    padding: 0.5rem 0 0.5rem 1.5rem;
    border-top: 1px solid var(--grid);
}

.plan__list li::before {
    content: '';
    position: absolute;
    left: 0.125rem;
    top: 1.05rem;
    width: 0.625rem;
    height: 0.3125rem;
    border-left: 2px solid var(--brand-text);
    border-bottom: 2px solid var(--brand-text);
    transform: rotate(-45deg);
}

.plans-faq {
    padding-block: clamp(3.5rem, 8vw, 5rem);
    background: var(--blueprint);
    border-top: 1px solid var(--grid);
}

.plans-faq__inner {
    display: grid;
    gap: 2rem;
}

@media (min-width: 52rem) {
    .plans-faq__inner {
        grid-template-columns: 1fr 2fr;
        gap: 4rem;
    }
}

.plans-faq h2 {
    font-size: clamp(1.75rem, 3.4vw, 2.5rem);
    font-weight: 600;
}

.plans-faq dl {
    margin: 0;
}

.plans-faq dl div {
    padding-block: 1.125rem;
    border-top: 1px solid var(--grid-strong);
}

.plans-faq dt {
    font-weight: 600;
}

.plans-faq dd {
    margin: 0.375rem 0 0;
    color: var(--ink-soft);
    max-width: var(--measure);
}
