
/* ==========================================================
   LLT Communications
   Notifications + Order Chat + iPhone safe-area correction
   ========================================================== */

.notification-trigger {
    position: relative;
    flex: 0 0 auto;
}

.notification-trigger svg {
    width: 22px;
    height: 22px;
    fill: none;
    stroke: currentColor;
    stroke-width: 1.8;
    stroke-linecap: round;
    stroke-linejoin: round;
}

.notification-badge {
    position: absolute;
    inset-block-start: -5px;
    inset-inline-end: -6px;
    min-width: 19px;
    height: 19px;
    padding: 0 5px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 999px;
    background: #e5485d;
    color: white;
    font-size: 10px;
    font-weight: 800;
    line-height: 1;
    border: 2px solid var(--surface, #111722);
    box-sizing: border-box;
}

.notification-backdrop {
    position: fixed;
    inset: 0;
    z-index: 980;
    background: rgba(0, 0, 0, .48);
    backdrop-filter: blur(3px);
}

.notification-center {
    position: fixed;
    z-index: 990;
    top: 82px;
    inset-inline-end: 18px;
    width: min(430px, calc(100vw - 36px));
    max-height: min(720px, calc(100vh - 110px));
    overflow: hidden;
    display: flex;
    flex-direction: column;
    border-radius: 24px;
    background: var(--surface, #fff);
    border: 1px solid var(--border, rgba(127,127,127,.2));
    box-shadow: 0 24px 70px rgba(0,0,0,.28);
    opacity: 0;
    visibility: hidden;
    transform: translateY(-8px) scale(.985);
    transition: opacity .18s ease, transform .18s ease, visibility .18s;
}

.notification-center.is-open {
    opacity: 1;
    visibility: visible;
    transform: translateY(0) scale(1);
}

.notification-center__handle {
    display: none;
}

.notification-center__head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    padding: 20px 20px 14px;
}

.notification-center__head h2 {
    margin: 3px 0 0;
    font-size: 1.35rem;
}

.notification-center__close {
    width: 40px;
    height: 40px;
    border-radius: 12px;
    border: 1px solid var(--border, rgba(127,127,127,.2));
    background: transparent;
    color: inherit;
    font-size: 24px;
    cursor: pointer;
}

.notification-center__toolbar {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 12px;
    padding: 10px 20px 14px;
    border-bottom: 1px solid var(--border, rgba(127,127,127,.14));
    font-size: .82rem;
    color: var(--muted, #8d96a8);
}

.notification-center__toolbar button {
    border: 0;
    padding: 0;
    background: transparent;
    color: #c9952b;
    font: inherit;
    font-weight: 700;
    cursor: pointer;
}

.notification-list {
    overflow-y: auto;
    padding: 10px;
    overscroll-behavior: contain;
}

.notification-empty {
    padding: 34px 20px;
    text-align: center;
    color: var(--muted, #8d96a8);
}

.notification-item {
    display: grid;
    grid-template-columns: 40px minmax(0, 1fr) auto;
    align-items: center;
    gap: 12px;
    padding: 13px 12px;
    margin-bottom: 5px;
    border-radius: 16px;
    text-decoration: none;
    color: inherit;
    transition: background .15s ease;
}

.notification-item:hover {
    background: rgba(127,127,127,.08);
}

.notification-item.is-unread {
    background: rgba(205, 157, 50, .09);
}

.notification-item__icon {
    width: 40px;
    height: 40px;
    display: grid;
    place-items: center;
    border-radius: 13px;
    background: rgba(205, 157, 50, .12);
    color: #d4a539;
    font-size: 18px;
}

.notification-item__copy {
    min-width: 0;
}

.notification-item__copy strong {
    display: block;
    line-height: 1.45;
    font-size: .91rem;
}

.notification-item__copy small {
    display: block;
    margin-top: 4px;
    color: var(--muted, #8d96a8);
}

.notification-item__dot {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: #d6a536;
}

.notification-item:not(.is-unread) .notification-item__dot {
    opacity: 0;
}


/* Order chat */

.order-chat-card {
    overflow: hidden;
}

.order-chat-head {
    align-items: center;
}

.chat-live-indicator {
    display: inline-flex;
    align-items: center;
    gap: 7px;
    color: var(--muted, #8d96a8);
    font-size: .78rem;
    font-weight: 700;
}

.chat-live-indicator > span {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: #2fb777;
    box-shadow: 0 0 0 4px rgba(47,183,119,.12);
}

.order-chat-messages {
    min-height: 180px;
    max-height: 440px;
    overflow-y: auto;
    padding: 20px;
    display: flex;
    flex-direction: column;
    gap: 12px;
    background: rgba(127,127,127,.025);
    border-block: 1px solid var(--border, rgba(127,127,127,.12));
    overscroll-behavior: contain;
}

.chat-empty {
    margin: auto;
    padding: 35px 15px;
    color: var(--muted, #8d96a8);
    text-align: center;
}

.chat-message {
    width: min(82%, 620px);
    align-self: flex-start;
}

html[dir="rtl"] .chat-message {
    align-self: flex-end;
}

.chat-message.is-mine {
    align-self: flex-end;
}

html[dir="rtl"] .chat-message.is-mine {
    align-self: flex-start;
}

.chat-message__bubble {
    padding: 11px 14px;
    border-radius: 17px 17px 17px 5px;
    background: var(--surface-2, rgba(127,127,127,.10));
    border: 1px solid var(--border, rgba(127,127,127,.12));
}

html[dir="rtl"] .chat-message__bubble {
    border-radius: 17px 17px 5px 17px;
}

.chat-message.is-mine .chat-message__bubble {
    background: rgba(205,157,50,.14);
    border-color: rgba(205,157,50,.28);
}

.chat-message__sender {
    display: block;
    margin-bottom: 4px;
    font-size: .75rem;
    color: #c7952c;
    font-weight: 800;
}

.chat-message__body {
    margin: 0;
    white-space: pre-wrap;
    overflow-wrap: anywhere;
    line-height: 1.55;
}

.chat-message__time {
    display: block;
    margin-top: 5px;
    color: var(--muted, #8d96a8);
    font-size: .69rem;
}

.order-chat-form {
    display: flex;
    align-items: flex-end;
    gap: 12px;
    padding: 16px 20px 20px;
}

.order-chat-form textarea {
    flex: 1 1 auto;
    min-height: 52px;
    max-height: 140px;
    resize: vertical;
    border-radius: 15px;
    border: 1px solid var(--border, rgba(127,127,127,.2));
    background: var(--surface-2, rgba(127,127,127,.05));
    color: inherit;
    padding: 13px 14px;
    font: inherit;
    line-height: 1.4;
    outline: none;
}

.order-chat-form textarea:focus {
    border-color: rgba(205,157,50,.62);
    box-shadow: 0 0 0 3px rgba(205,157,50,.10);
}

.order-chat-form .btn {
    min-height: 52px;
    flex: 0 0 auto;
}


/* iPhone / Android installed app header */
@media (max-width: 820px) {
    .app-header {
        height: auto !important;
        padding-top: env(safe-area-inset-top, 0px);
    }

    .app-header__inner {
        min-height: 66px;
        height: auto !important;
        padding-top: 8px;
        padding-bottom: 8px;
    }

    .header-actions {
        gap: 8px;
    }

    .notification-trigger,
    .mobile-account-trigger,
    .theme-toggle {
        flex-shrink: 0;
    }

    .brand__logo {
        max-height: 44px;
        width: auto;
    }

    .notification-center {
        top: auto;
        inset-inline: 8px;
        bottom: calc(8px + env(safe-area-inset-bottom, 0px));
        width: auto;
        max-height: min(76vh, 700px);
        border-radius: 26px;
        transform: translateY(24px);
    }

    .notification-center.is-open {
        transform: translateY(0);
    }

    .notification-center__handle {
        display: block;
        width: 42px;
        height: 5px;
        border-radius: 99px;
        background: rgba(127,127,127,.35);
        margin: 9px auto 1px;
    }

    .notification-center__head {
        padding-top: 12px;
    }

    .order-chat-messages {
        max-height: 52vh;
        padding: 14px;
    }

    .chat-message {
        width: 88%;
    }

    .order-chat-form {
        padding: 12px;
        gap: 8px;
    }

    .order-chat-form .btn {
        min-width: 82px;
        padding-inline: 14px;
    }
}

@media (display-mode: standalone) and (max-width: 820px) {
    .app-header {
        padding-top: max(env(safe-area-inset-top, 0px), 8px);
    }
}


/* ==========================================================
   Per-order Chat shortcuts
   ========================================================== */

.order-chat-shortcut {
    position: relative;
    width: fit-content;
    min-height: 36px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 7px;
    padding: 7px 11px;
    border-radius: 12px;
    border: 1px solid rgba(127,127,127,.20);
    background: rgba(127,127,127,.055);
    color: inherit;
    text-decoration: none;
    font-size: .78rem;
    font-weight: 800;
    line-height: 1;
    transition:
        transform .16s ease,
        border-color .16s ease,
        background .16s ease,
        box-shadow .16s ease;
    z-index: 4;
}

.order-chat-shortcut:hover {
    transform: translateY(-1px);
    border-color: rgba(205,157,50,.48);
    background: rgba(205,157,50,.08);
}

.order-chat-shortcut__icon {
    font-size: 15px;
    line-height: 1;
}

.order-chat-shortcut__badge {
    min-width: 19px;
    height: 19px;
    padding: 0 5px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 999px;
    background: #e5485d;
    color: #fff;
    font-size: 10px;
    font-weight: 900;
    line-height: 1;
    box-shadow: 0 0 0 2px var(--surface, #111722);
}

.order-chat-shortcut.is-unread {
    color: #e1b64e;
    border-color: rgba(221,174,63,.55);
    background: rgba(205,157,50,.11);
    box-shadow:
        0 0 0 1px rgba(205,157,50,.06),
        0 0 18px rgba(205,157,50,.13);
    animation: llt-chat-unread-pulse 2.2s ease-in-out infinite;
}

.order-chat-shortcut.is-new-arrival {
    animation: llt-chat-arrival .72s cubic-bezier(.2,.8,.2,1) 1;
}

@keyframes llt-chat-unread-pulse {
    0%, 100% {
        box-shadow:
            0 0 0 0 rgba(205,157,50,.13),
            0 0 12px rgba(205,157,50,.10);
    }

    50% {
        box-shadow:
            0 0 0 5px rgba(205,157,50,.06),
            0 0 24px rgba(205,157,50,.22);
    }
}

@keyframes llt-chat-arrival {
    0% {
        transform: scale(1);
    }

    32% {
        transform: scale(1.10) rotate(-2deg);
    }

    58% {
        transform: scale(.98) rotate(1deg);
    }

    100% {
        transform: scale(1);
    }
}

.order-chat-shortcut--desktop {
    margin-top: 7px;
}

.order-card__actions {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-top: 13px;
}

.order-chat-shortcut--mobile {
    min-height: 43px;
    padding-inline: 14px;
    font-size: .84rem;
}

@media (max-width: 820px) {
    .order-chat-shortcut--desktop {
        display: none;
    }

    .order-chat-shortcut--mobile {
        width: 100%;
    }
}

@media (prefers-reduced-motion: reduce) {
    .order-chat-shortcut.is-unread,
    .order-chat-shortcut.is-new-arrival {
        animation: none !important;
    }
}


/* ==========================================================
   What's New / Release Notice
   ========================================================== */

.release-update-backdrop {
    position: fixed;
    inset: 0;
    z-index: 1990;
    background: rgba(3, 6, 12, .72);
    backdrop-filter: blur(8px);
}

.release-update-modal {
    position: fixed;
    z-index: 2000;
    top: 50%;
    left: 50%;
    width: min(520px, calc(100vw - 32px));
    max-height: calc(100vh - 42px);
    overflow-y: auto;
    transform: translate(-50%, -50%);
    padding: 28px;
    border-radius: 28px;
    background: var(--surface, #fff);
    color: inherit;
    border: 1px solid rgba(205,157,50,.28);
    box-shadow: 0 34px 90px rgba(0,0,0,.42);
    animation: llt-release-enter .36s cubic-bezier(.2,.85,.25,1);
}

.release-update-modal__icon {
    width: 54px;
    height: 54px;
    display: grid;
    place-items: center;
    margin-bottom: 17px;
    border-radius: 17px;
    background: rgba(205,157,50,.13);
    color: #d5a738;
    font-size: 27px;
}

.release-update-modal__head h2 {
    margin: 4px 0 8px;
    font-size: 1.65rem;
}

.release-update-modal__head p {
    margin: 0;
    color: var(--muted, #8892a4);
    line-height: 1.6;
}

.release-update-features {
    display: grid;
    gap: 10px;
    margin-top: 22px;
}

.release-update-feature {
    display: grid;
    grid-template-columns: 42px minmax(0,1fr);
    gap: 12px;
    align-items: center;
    padding: 13px;
    border-radius: 16px;
    background: rgba(127,127,127,.055);
    border: 1px solid rgba(127,127,127,.10);
}

.release-update-feature > span {
    width: 42px;
    height: 42px;
    display: grid;
    place-items: center;
    border-radius: 13px;
    background: rgba(205,157,50,.10);
    font-size: 19px;
}

.release-update-feature strong,
.release-update-feature small {
    display: block;
}

.release-update-feature small {
    margin-top: 4px;
    color: var(--muted, #8892a4);
    line-height: 1.45;
}

.release-update-modal__action {
    margin-top: 22px;
}

.release-update-modal__action .btn {
    width: 100%;
    min-height: 50px;
}

@keyframes llt-release-enter {
    from {
        opacity: 0;
        transform: translate(-50%, -46%) scale(.96);
    }

    to {
        opacity: 1;
        transform: translate(-50%, -50%) scale(1);
    }
}

@media (max-width: 600px) {
    .release-update-modal {
        width: calc(100vw - 20px);
        padding: 21px;
        border-radius: 24px;
        max-height: calc(
            100vh -
            env(safe-area-inset-top, 0px) -
            env(safe-area-inset-bottom, 0px) -
            24px
        );
    }

    .release-update-modal__head h2 {
        font-size: 1.45rem;
    }
}

@media (prefers-reduced-motion: reduce) {
    .release-update-modal {
        animation: none;
    }
}


/* ==========================================================
   LLT Professional Icon System
   ========================================================== */

.ui-icon {
    width: 1.15em;
    height: 1.15em;
    display: inline-block;
    flex: 0 0 auto;
    fill: none;
    stroke: currentColor;
    stroke-width: 1.8;
    stroke-linecap: round;
    stroke-linejoin: round;
    vertical-align: -0.18em;
}

.btn .ui-icon,
.order-chat-shortcut .ui-icon,
.archive-badge .ui-icon,
.back-link .ui-icon {
    width: 18px;
    height: 18px;
}

.theme-icon .ui-icon {
    width: 20px;
    height: 20px;
}

.sheet-chevron .ui-icon,
.order-card__chevron .ui-icon {
    width: 19px;
    height: 19px;
}

.notification-item__icon .ui-icon {
    width: 20px;
    height: 20px;
}

.release-update-modal__icon .ui-icon {
    width: 26px;
    height: 26px;
}

.release-update-feature > span .ui-icon {
    width: 21px;
    height: 21px;
}

.empty-state__icon .ui-icon {
    width: 32px;
    height: 32px;
}

.search-icon .ui-icon {
    width: 18px;
    height: 18px;
}

.order-chat-shortcut__icon .ui-icon {
    width: 17px;
    height: 17px;
}

.copy-button--icon .ui-icon {
    width: 16px;
    height: 16px;
}

