/*
 * WRYEDGE DIRECT 2.0
 * Shopping Assistant
 * v0.1.0-alpha1
 */


:root {
    --wd-sa-accent:
        #d72c3f;

    --wd-sa-accent-soft:
        rgba(215, 44, 63, .075);

    --wd-sa-green:
        #12845f;

    --wd-sa-green-soft:
        rgba(18, 132, 95, .075);

    --wd-sa-blue:
        #315fca;

    --wd-sa-border:
        rgba(28, 40, 61, .11);

    --wd-sa-border-strong:
        rgba(28, 40, 61, .17);

    --wd-sa-muted:
        #697386;

    --wd-sa-soft:
        #f7f8fa;

    --wd-sa-panel:
        #ffffff;

    --wd-sa-shadow:
        0 16px 46px
        rgba(22, 34, 54, .055);
}


/* =========================================================
   PAGE
   ========================================================= */

.wd-sa-page {
    padding:
        24px 0
        72px;
}


.wd-sa-container {
    min-width: 0;
}


.wd-sa-breadcrumbs {
    display: flex;
    align-items: center;

    gap: 8px;

    margin-bottom: 34px;

    color:
        var(--wd-sa-muted);

    font-size: 13px;
}


.wd-sa-breadcrumbs a {
    color: inherit;
    text-decoration: none;
}


.wd-sa-breadcrumbs a:hover {
    color: #202938;
}


/* =========================================================
   HERO
   ========================================================= */

.wd-sa-hero {
    display: grid;

    grid-template-columns:
        minmax(0, 1fr)
        minmax(320px, 420px);

    align-items: end;

    gap: 48px;

    margin-bottom: 34px;
}


.wd-sa-eyebrow {
    margin-bottom: 10px;

    color:
        var(--wd-sa-accent);

    font-size: 12px;
    font-weight: 750;

    letter-spacing: .075em;

    text-transform: uppercase;
}


.wd-sa-hero h1 {
    max-width: 760px;

    margin:
        0 0
        14px;

    font-size:
        clamp(
            18px,
            1.7vw,
            24px
        );

    line-height: 1.12;

    letter-spacing:
        -.02em;
}


.wd-sa-hero__copy > p {
    max-width: 720px;

    margin: 0;

    color:
        var(--wd-sa-muted);

    font-size: 16px;
    line-height: 1.62;
}


.wd-sa-runtime {
    padding: 18px;

    border:
        1px solid
        var(--wd-sa-border);

    border-radius: 15px;

    background:
        linear-gradient(
            145deg,
            rgba(255,255,255,.97),
            rgba(247,249,252,.94)
        );

    box-shadow:
        var(--wd-sa-shadow);
}


.wd-sa-runtime__item {
    display: flex;
    align-items: center;

    gap: 12px;
}


.wd-sa-runtime-dot {
    width: 10px;
    height: 10px;

    flex: 0 0 auto;

    border-radius: 999px;

    background:
        var(--wd-sa-green);

    box-shadow:
        0 0 0 5px
        rgba(18, 132, 95, .10);
}


.wd-sa-runtime__item div {
    display: flex;
    flex-direction: column;

    gap: 2px;
}


.wd-sa-runtime__item strong {
    font-size: 14px;
}


.wd-sa-runtime__item small {
    color:
        var(--wd-sa-muted);

    font-size: 12px;
}


.wd-sa-runtime__line {
    height: 1px;

    margin:
        15px 0;

    background:
        var(--wd-sa-border);
}


.wd-sa-runtime__facts {
    display: flex;
    flex-wrap: wrap;

    gap:
        7px 14px;
}


.wd-sa-runtime__facts span {
    position: relative;

    padding-left: 13px;

    color:
        var(--wd-sa-muted);

    font-size: 11px;
}


.wd-sa-runtime__facts span::before {
    content: "";

    position: absolute;

    left: 0;
    top: 50%;

    width: 5px;
    height: 5px;

    margin-top: -2px;

    border-radius: 50%;

    background:
        #95a0b0;
}


/* =========================================================
   QUICK START
   ========================================================= */

.wd-sa-quick-start {
    display: grid;

    grid-template-columns:
        repeat(
            4,
            minmax(0, 1fr)
        );

    gap: 12px;

    margin-bottom: 18px;
}


.wd-sa-quick-start button {
    display: flex;
    align-items: flex-start;

    gap: 12px;

    min-width: 0;

    padding: 15px;

    border:
        1px solid
        var(--wd-sa-border);

    border-radius: 12px;

    background:
        #fff;

    color: inherit;

    text-align: left;

    cursor: pointer;

    transition:
        transform .16s ease,
        border-color .16s ease,
        box-shadow .16s ease;
}


.wd-sa-quick-start button:hover {
    transform:
        translateY(-2px);

    border-color:
        var(--wd-sa-border-strong);

    box-shadow:
        0 10px 28px
        rgba(20, 33, 53, .06);
}


.wd-sa-quick-start__icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;

    width: 34px;
    height: 34px;

    flex: 0 0 auto;

    border-radius: 9px;

    background:
        var(--wd-sa-accent-soft);

    color:
        var(--wd-sa-accent);

    font-size: 10px;
    font-weight: 850;
}


.wd-sa-quick-start button > span:last-child {
    display: flex;
    flex-direction: column;

    min-width: 0;

    gap: 4px;
}


.wd-sa-quick-start strong {
    font-size: 13px;
}


.wd-sa-quick-start small {
    color:
        var(--wd-sa-muted);

    font-size: 11px;
    line-height: 1.45;
}


/* =========================================================
   WORKSPACE
   ========================================================= */

.wd-sa-workspace {
    display: grid;

    grid-template-columns:
        minmax(0, 1fr)
        340px;

    align-items: start;

    gap: 18px;
}


/* =========================================================
   CHAT
   ========================================================= */

.wd-sa-chat {
    display: flex;
    flex-direction: column;

    min-width: 0;

    min-height: 690px;

    overflow: hidden;

    border:
        1px solid
        var(--wd-sa-border);

    border-radius: 15px;

    background:
        #fff;

    box-shadow:
        var(--wd-sa-shadow);
}


.wd-sa-chat__header {
    display: flex;
    align-items: center;
    justify-content: space-between;

    gap: 16px;

    min-height: 72px;

    padding:
        14px 17px;

    border-bottom:
        1px solid
        var(--wd-sa-border);
}


.wd-sa-chat__identity {
    display: flex;
    align-items: center;

    gap: 11px;
}


.wd-sa-avatar {
    display: inline-flex;
    align-items: center;
    justify-content: center;

    width: 39px;
    height: 39px;

    flex: 0 0 auto;

    border-radius: 11px;

    background:
        linear-gradient(
            145deg,
            #e13b4d,
            #bd2034
        );

    color: #fff;

    font-size: 17px;
    font-weight: 850;

    box-shadow:
        0 7px 18px
        rgba(194, 31, 51, .18);
}


.wd-sa-chat__identity > div:last-child {
    display: flex;
    flex-direction: column;

    gap: 1px;
}


.wd-sa-chat__identity strong {
    font-size: 14px;
}


.wd-sa-chat__identity span {
    color:
        var(--wd-sa-muted);

    font-size: 11px;
}


.wd-sa-new-conversation {
    min-height: 34px;

    padding:
        0 11px;

    border:
        1px solid
        var(--wd-sa-border);

    border-radius: 8px;

    background:
        #fff;

    color:
        var(--wd-sa-muted);

    font-size: 11px;
    font-weight: 650;

    cursor: pointer;
}


.wd-sa-new-conversation:hover {
    color: #202938;

    border-color:
        var(--wd-sa-border-strong);
}


/* MESSAGES */

.wd-sa-messages {
    flex: 1;

    min-height: 0;

    overflow-y: auto;

    padding:
        24px 22px;

    scroll-behavior: smooth;
}


.wd-sa-welcome {
    display: flex;
    flex-direction: column;

    justify-content: center;

    min-height: 380px;

    max-width: 650px;

    margin: 0 auto;

    text-align: center;
}


.wd-sa-welcome__mark {
    display: inline-flex;
    align-items: center;
    justify-content: center;

    width: 54px;
    height: 54px;

    margin:
        0 auto
        17px;

    border-radius: 16px;

    background:
        var(--wd-sa-accent-soft);

    color:
        var(--wd-sa-accent);

    font-size: 23px;
    font-weight: 850;
}


.wd-sa-welcome h2 {
    margin:
        0 0
        9px;

    font-size: 24px;

    letter-spacing:
        -.025em;
}


.wd-sa-welcome p {
    max-width: 580px;

    margin:
        0 auto;

    color:
        var(--wd-sa-muted);

    font-size: 14px;
    line-height: 1.65;
}


.wd-sa-message {
    display: flex;
    flex-direction: column;

    max-width: 82%;

    margin-bottom: 21px;
}


.wd-sa-message--user {
    align-items: flex-end;

    margin-left: auto;
}


.wd-sa-message--assistant {
    align-items: flex-start;

    margin-right: auto;
}


.wd-sa-message__label {
    margin:
        0 0
        6px;

    color:
        var(--wd-sa-muted);

    font-size: 10px;
    font-weight: 700;

    letter-spacing: .035em;

    text-transform: uppercase;
}


.wd-sa-message__bubble {
    padding:
        12px 14px;

    border-radius: 13px;

    font-size: 13px;
    line-height: 1.65;

    white-space: pre-wrap;

    overflow-wrap: anywhere;
}


.wd-sa-message--user
.wd-sa-message__bubble {
    border:
        1px solid
        rgba(215, 44, 63, .16);

    background:
        var(--wd-sa-accent-soft);
}


.wd-sa-message--assistant
.wd-sa-message__bubble {
    border:
        1px solid
        var(--wd-sa-border);

    background:
        #f8f9fb;
}


.wd-sa-typing {
    display: inline-flex;

    gap: 4px;

    padding:
        5px 2px;
}


.wd-sa-typing span {
    width: 6px;
    height: 6px;

    border-radius: 999px;

    background:
        #8994a4;

    animation:
        wd-sa-typing
        1s
        infinite ease-in-out;
}


.wd-sa-typing span:nth-child(2) {
    animation-delay:
        .14s;
}


.wd-sa-typing span:nth-child(3) {
    animation-delay:
        .28s;
}


@keyframes wd-sa-typing {

    0%,
    60%,
    100% {
        opacity: .34;
        transform:
            translateY(0);
    }

    30% {
        opacity: 1;
        transform:
            translateY(-2px);
    }
}


/* STATUS */

.wd-sa-status {
    min-height: 19px;

    padding:
        0 18px;

    color:
        var(--wd-sa-muted);

    font-size: 11px;
}


/* COMPOSER */

.wd-sa-composer {
    display: grid;

    grid-template-columns:
        minmax(0, 1fr)
        auto;

    align-items: end;

    gap: 10px;

    margin:
        0 16px;

    padding:
        10px;

    border:
        1px solid
        var(--wd-sa-border-strong);

    border-radius: 13px;

    background:
        #fff;

    transition:
        border-color .16s ease,
        box-shadow .16s ease;
}


.wd-sa-composer:focus-within {
    border-color:
        rgba(215, 44, 63, .38);

    box-shadow:
        0 0 0 3px
        rgba(215, 44, 63, .055);
}


.wd-sa-composer textarea {
    width: 100%;
    min-height: 43px;
    max-height: 180px;

    resize: none;

    padding:
        10px 8px;

    border: 0;
    outline: 0;

    background:
        transparent;

    color: inherit;

    font: inherit;
    font-size: 13px;
    line-height: 1.48;
}


.wd-sa-composer button {
    display: inline-flex;
    align-items: center;

    gap: 7px;

    min-height: 41px;

    padding:
        0 14px;

    border: 0;

    border-radius: 9px;

    background:
        var(--wd-sa-accent);

    color: #fff;

    font-size: 12px;
    font-weight: 750;

    cursor: pointer;
}


.wd-sa-composer button:hover:not(:disabled) {
    background:
        #bf2235;
}


.wd-sa-composer button:disabled {
    opacity: .55;
    cursor: default;
}


.wd-sa-composer button svg {
    width: 16px;
    height: 16px;

    fill: none;
    stroke: currentColor;

    stroke-width: 1.8;

    stroke-linecap: round;
    stroke-linejoin: round;
}


.wd-sa-chat__note {
    margin:
        10px 18px
        15px;

    color:
        var(--wd-sa-muted);

    font-size: 10px;
    line-height: 1.45;

    text-align: center;
}


/* =========================================================
   SIDEBAR
   ========================================================= */

.wd-sa-sidebar {
    display: flex;
    flex-direction: column;

    gap: 14px;
}


.wd-sa-panel {
    overflow: hidden;

    border:
        1px solid
        var(--wd-sa-border);

    border-radius: 13px;

    background:
        #fff;
}


.wd-sa-panel__header {
    display: flex;
    align-items: center;
    justify-content: space-between;

    gap: 16px;

    padding:
        15px 16px;

    border-bottom:
        1px solid
        var(--wd-sa-border);
}


.wd-sa-panel__header > div {
    display: flex;
    flex-direction: column;

    gap: 2px;
}


.wd-sa-panel__header span {
    color:
        var(--wd-sa-muted);

    font-size: 9px;
    font-weight: 700;

    letter-spacing: .06em;

    text-transform: uppercase;
}


.wd-sa-panel__header h2 {
    margin: 0;

    font-size: 15px;
}


/* REQUIREMENTS */

.wd-sa-requirements {
    display: flex;
    flex-direction: column;

    gap: 14px;

    padding: 15px;
}


.wd-sa-requirements > label {
    display: flex;
    flex-direction: column;

    gap: 6px;
}


.wd-sa-requirements > label > span,
.wd-sa-requirements legend {
    color:
        #4d5869;

    font-size: 11px;
    font-weight: 650;
}


.wd-sa-requirements select,
.wd-sa-requirements textarea,
.wd-sa-budget {
    width: 100%;

    border:
        1px solid
        var(--wd-sa-border-strong);

    border-radius: 8px;

    background:
        #fff;
}


.wd-sa-requirements select {
    height: 38px;

    padding:
        0 10px;

    color: inherit;

    font-size: 12px;
}


.wd-sa-requirements textarea {
    min-height: 92px;

    resize: vertical;

    padding: 10px;

    color: inherit;

    font: inherit;
    font-size: 12px;
    line-height: 1.5;
}


.wd-sa-budget {
    display: flex;
    align-items: center;

    overflow: hidden;
}


.wd-sa-budget > span {
    padding-left: 10px;

    color:
        var(--wd-sa-muted);

    font-size: 13px;
}


.wd-sa-budget input {
    width: 100%;
    height: 36px;

    min-width: 0;

    padding:
        0 9px;

    border: 0;
    outline: 0;

    background:
        transparent;

    color: inherit;

    font: inherit;
    font-size: 12px;
}


.wd-sa-requirements fieldset {
    display: grid;

    grid-template-columns:
        1fr 1fr;

    gap: 8px;

    margin: 0;
    padding: 0;

    border: 0;
}


.wd-sa-requirements legend {
    grid-column: 1 / -1;

    margin-bottom: 2px;
}


.wd-sa-check {
    display: flex;
    align-items: center;

    gap: 7px;

    min-width: 0;

    padding: 8px;

    border:
        1px solid
        var(--wd-sa-border);

    border-radius: 7px;

    cursor: pointer;
}


.wd-sa-check input {
    margin: 0;
}


.wd-sa-check span {
    color:
        #4d5869;

    font-size: 10px;
    line-height: 1.3;
}


.wd-sa-use-requirements {
    min-height: 40px;

    padding:
        0 12px;

    border:
        1px solid
        rgba(215, 44, 63, .19);

    border-radius: 8px;

    background:
        var(--wd-sa-accent-soft);

    color:
        #aa2334;

    font-size: 11px;
    font-weight: 750;

    cursor: pointer;
}


.wd-sa-use-requirements:hover {
    border-color:
        rgba(215, 44, 63, .31);

    background:
        rgba(215, 44, 63, .10);
}


/* SHORTLIST */

.wd-sa-shortlist-count {
    display: inline-flex;
    align-items: center;
    justify-content: center;

    min-width: 27px;
    height: 27px;

    border-radius: 999px;

    background:
        var(--wd-sa-soft);

    color:
        var(--wd-sa-muted);

    font-size: 11px;
}


.wd-sa-shortlist-empty {
    display: flex;
    flex-direction: column;
    align-items: center;

    padding:
        26px 20px;

    text-align: center;
}


.wd-sa-shortlist-empty__icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;

    width: 36px;
    height: 36px;

    margin-bottom: 10px;

    border:
        1px dashed
        var(--wd-sa-border-strong);

    border-radius: 10px;

    color:
        var(--wd-sa-muted);

    font-size: 20px;
}


.wd-sa-shortlist-empty strong {
    font-size: 12px;
}


.wd-sa-shortlist-empty p {
    margin:
        7px 0
        12px;

    color:
        var(--wd-sa-muted);

    font-size: 10px;
    line-height: 1.5;
}


.wd-sa-shortlist-empty a {
    color:
        var(--wd-sa-accent);

    font-size: 11px;
    font-weight: 700;

    text-decoration: none;
}


/* TRUST */

.wd-sa-trust {
    padding:
        15px 16px;

    border:
        1px solid
        rgba(18, 132, 95, .16);

    border-radius: 13px;

    background:
        var(--wd-sa-green-soft);
}


.wd-sa-trust strong {
    color:
        #126b51;

    font-size: 11px;
}


.wd-sa-trust ul {
    display: flex;
    flex-direction: column;

    gap: 7px;

    margin:
        10px 0 0;

    padding:
        0;

    list-style: none;
}


.wd-sa-trust li {
    position: relative;

    padding-left: 15px;

    color:
        #527066;

    font-size: 10px;
    line-height: 1.4;
}


.wd-sa-trust li::before {
    content: "✓";

    position: absolute;

    left: 0;

    color:
        var(--wd-sa-green);

    font-weight: 800;
}


/* =========================================================
   RESPONSIVE
   ========================================================= */

@media (max-width: 1180px) {

    .wd-sa-quick-start {
        grid-template-columns:
            repeat(
                2,
                minmax(0, 1fr)
            );
    }


    .wd-sa-workspace {
        grid-template-columns:
            minmax(0, 1fr)
            310px;
    }

}


@media (max-width: 920px) {

    .wd-sa-hero {
        grid-template-columns:
            1fr;

        gap: 22px;
    }


    .wd-sa-runtime {
        max-width: 520px;
    }


    .wd-sa-workspace {
        grid-template-columns:
            1fr;
    }


    .wd-sa-sidebar {
        display: grid;

        grid-template-columns:
            1fr 1fr;

        align-items: start;
    }


    .wd-sa-trust {
        grid-column:
            1 / -1;
    }


    .wd-sa-chat {
        min-height: 640px;
    }

}


@media (max-width: 640px) {

    .wd-sa-page {
        padding-top: 17px;
    }


    .wd-sa-breadcrumbs {
        margin-bottom: 24px;
    }


    .wd-sa-hero {
        margin-bottom: 25px;
    }


    .wd-sa-hero h1 {
        font-size:
            clamp(
                18px,
                5.4vw,
                24px
            );
    }


    .wd-sa-hero__copy > p {
        font-size: 14px;
    }


    .wd-sa-quick-start {
        grid-template-columns:
            1fr;
    }


    .wd-sa-sidebar {
        display: flex;
    }


    .wd-sa-chat {
        min-height:
            calc(100vh - 150px);

        border-radius: 11px;
    }


    .wd-sa-chat__header {
        min-height: 64px;

        padding:
            11px 12px;
    }


    .wd-sa-new-conversation {
        padding:
            0 8px;

        font-size: 10px;
    }


    .wd-sa-messages {
        padding:
            18px 13px;
    }


    .wd-sa-message {
        max-width: 92%;
    }


    .wd-sa-composer {
        margin:
            0 10px;

        padding: 7px;
    }


    .wd-sa-composer button {
        padding:
            0 11px;
    }


    .wd-sa-composer button span {
        display: none;
    }


    .wd-sa-chat__note {
        margin:
            8px 12px
            12px;
    }

}
