﻿:root {
    --bg-1: #e6f2ff;
    --bg-2: #cfe4ff;
    --bg-3: #b7d8ff;
    --ink: #0d2b4d;
    --ink-soft: #3a5b7a;
    --primary: #2f73d9;
    --primary-2: #4aa0ff;
    --accent: #7cc0ff;
    --card: rgba(255, 255, 255, 0.78);
    --glass: rgba(255, 255, 255, 0.55);
    --shadow: 0 20px 50px rgba(5, 44, 84, 0.15);
    --radius: 20px;
    --topbar-height: 64px;
}

* {
    box-sizing: border-box;
}

html, body {
    height: 100%;
}

body {
    margin: 0;
    font-family: "Manrope", "Raleway", sans-serif;
    color: var(--ink);
    padding-top: 0;
    background: radial-gradient(circle at 20% 10%, var(--bg-3), transparent 50%),
        radial-gradient(circle at 80% 0%, var(--bg-2), transparent 45%),
        linear-gradient(160deg, var(--bg-1), #f8fbff 60%);
    overflow-x: hidden;
}

.bg-orb {
    position: fixed;
    width: 380px;
    height: 380px;
    border-radius: 50%;
    filter: blur(40px);
    opacity: 0.6;
    z-index: 0;
    pointer-events: none;
}

.bg-orb-1 {
    top: -120px;
    right: -80px;
    background: radial-gradient(circle, rgba(74, 160, 255, 0.6), transparent 60%);
}

.bg-orb-2 {
    bottom: -160px;
    left: -120px;
    background: radial-gradient(circle, rgba(47, 115, 217, 0.5), transparent 60%);
}

.page {
    max-width: 1100px;
    margin: 0 auto;
    padding: calc(var(--topbar-height) + 10px) 20px 60px;
    position: relative;
    z-index: 1;
}

.page--with-topbar {
    padding-top: 96px;
}

.topbar {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin: 0;
    padding: 10px 20px;
    border-radius: 0;
    background: rgba(255, 255, 255, 0.7);
    border: 1px solid rgba(255, 255, 255, 0.5);
    box-shadow: 0 12px 28px rgba(8, 46, 86, 0.12);
    backdrop-filter: blur(10px);
    gap: 10px;
    flex-wrap: wrap;
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    width: 100%;
    z-index: 5;
    min-height: var(--topbar-height);
}

.topbar--fixed {
    position: fixed;
    top: 16px;
    left: 50%;
    transform: translateX(-50%);
    width: min(1100px, calc(100% - 40px));
    z-index: 5;
}

.topbar__brand {
    display: flex;
    align-items: center;
    gap: 0;
}

.topbar__logo {
    height: 42px;
    width: auto;
    border-radius: 0;
    object-fit: contain;
    background: transparent;
    box-shadow: none;
}

.topbar__actions {
    display: flex;
    align-items: center;
    gap: 10px;
    flex-wrap: wrap;
}

.topbar__link {
    text-decoration: none;
    font-weight: 700;
    font-size: 13px;
    color: #fff;
    background: linear-gradient(135deg, var(--primary), var(--primary-2));
    padding: 10px 18px;
    border-radius: 999px;
    box-shadow: 0 12px 24px rgba(47, 115, 217, 0.25);
    transition: transform 0.18s ease, box-shadow 0.18s ease;
}

.topbar__link--danger {
    background: linear-gradient(135deg, #ffb3b3, #ff8f8f);
    color: #7a1b1b;
    box-shadow: 0 12px 24px rgba(200, 60, 60, 0.2);
}

.topbar__toggle {
    display: none;
    border: none;
    border-radius: 999px;
    background: rgba(47, 115, 217, 0.12);
    color: var(--primary);
    padding: 10px 12px;
    font-weight: 700;
    cursor: pointer;
    box-shadow: 0 8px 16px rgba(47, 115, 217, 0.18);
}

.hamburger {
    display: inline-flex;
    flex-direction: column;
    gap: 4px;
}

.hamburger span {
    width: 22px;
    height: 2px;
    background: var(--primary);
    border-radius: 2px;
}

@media (max-width: 760px) {
    .topbar {
        padding: 10px;
    }

    .topbar__brand {
        width: 100%;
        justify-content: space-between;
    }

    .topbar__actions {
        width: 100%;
        gap: 8px;
        display: none;
        margin-top: 8px;
    }

    .topbar__link {
        flex: 1 1 calc(50% - 8px);
        text-align: center;
        font-size: 12px;
        padding: 9px 10px;
    }

    .topbar__toggle {
        display: inline-flex;
        align-items: center;
        justify-content: center;
        width: 100%;
        margin-top: 8px;
    }

    .topbar--open .topbar__actions {
        display: flex;
    }

    .topbar__toggle[aria-expanded="true"] + .topbar__actions {
        display: flex;
    }
}

.docs-container {
    display: grid;
    gap: 12px;
    margin-top: 8px;
}

.doc-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    margin-top: 18px;
}

.doc-hint {
    font-size: 12px;
    color: var(--ink-soft);
    margin-top: 4px;
}

.doc-row {
    display: grid;
    grid-template-columns: 2.4fr 1.5fr 3.8fr auto;
    gap: 18px;
    align-items: center;
    padding: 14px;
    border-radius: 14px;
    background: rgba(255, 255, 255, 0.7);
    border: 1px solid rgba(255, 255, 255, 0.5);
    box-shadow: inset 0 1px 2px rgba(255,255,255,0.6), 0 10px 18px rgba(8, 46, 86, 0.08);
}

.doc-col input,
.doc-col .select {
    margin: 0;
}

.doc-col input,
.doc-col .select select {
    height: 54px;
    font-size: 16px;
}

.doc-col .select {
    padding: 4px;
}

.doc-col .select select {
    height: 44px;
}

.doc-col--triple {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    column-gap: 20px;
    row-gap: 16px;
    align-items: center;
}

.doc-col--actions {
    display: flex;
    justify-content: center;
}

.entrega {
    padding: 14px;
    border-radius: 16px;
    background: rgba(255, 255, 255, 0.7);
    border: 1px solid rgba(255, 255, 255, 0.5);
    box-shadow: 0 12px 24px rgba(8, 46, 86, 0.12);
    margin-bottom: 16px;
}

.entrega--done {
    background: rgba(210, 230, 255, 0.7);
    border-color: rgba(120, 170, 230, 0.6);
}

.entrega--pending {
    background: rgba(255, 220, 220, 0.6);
    border-color: rgba(230, 140, 140, 0.5);
}

.entrega__header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
}

.entrega__meta {
    font-size: 12px;
    color: var(--ink-soft);
    margin-top: 4px;
}

.modal {
    position: fixed;
    inset: 0;
    display: none;
    align-items: center;
    justify-content: center;
    z-index: 30;
}

.modal.is-open {
    display: flex;
}

.modal__backdrop {
    position: absolute;
    inset: 0;
    background: rgba(8, 20, 40, 0.45);
    backdrop-filter: blur(4px);
}

.modal__content {
    position: relative;
    width: min(720px, calc(100% - 32px));
    background: rgba(255, 255, 255, 0.9);
    border: 1px solid rgba(255, 255, 255, 0.6);
    border-radius: 18px;
    box-shadow: 0 24px 60px rgba(6, 28, 56, 0.25);
    z-index: 1;
}

.modal__header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 14px 16px;
    border-bottom: 1px solid rgba(122, 170, 220, 0.35);
}

.modal__body {
    padding: 16px;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
}

.signature-time {
    font-size: 12px;
    color: var(--ink-soft);
    margin-bottom: 10px;
}
.modal__body img {
    max-width: 100%;
    max-height: 60vh;
    background: #fff;
    border-radius: 12px;
    border: 1px solid rgba(122, 170, 220, 0.35);
}

.modal__close {
    width: 30px;
    height: 30px;
}

@media (max-width: 900px) {
    .doc-row {
        grid-template-columns: 1fr;
    }

    .doc-col--triple {
        grid-template-columns: 1fr;
    }
}

.topbar__link:hover {
    transform: translateY(-1px);
    box-shadow: 0 16px 30px rgba(47, 115, 217, 0.3);
}

.hero {
    text-align: left;
    margin-bottom: 28px;
}

.hero__badge {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 6px 14px;
    background: var(--glass);
    border-radius: 999px;
    font-size: 12px;
    letter-spacing: 0.12em;
    text-transform: uppercase;
    color: var(--ink-soft);
    box-shadow: 0 10px 30px rgba(47, 115, 217, 0.15);
}

.hero h1 {
    margin: 16px 0 12px;
    font-family: "Raleway", sans-serif;
    font-size: clamp(28px, 4vw, 46px);
    line-height: 1.05;
    letter-spacing: -0.02em;
}

.hero h1 span {
    display: block;
    font-size: clamp(20px, 2.8vw, 30px);
    color: var(--primary);
}

.hero p {
    margin: 0;
    max-width: 520px;
    color: var(--ink-soft);
}

.card {
    background: var(--card);
    border: 1px solid rgba(255, 255, 255, 0.45);
    border-radius: var(--radius);
    box-shadow: var(--shadow);
    backdrop-filter: blur(14px);
    padding: 24px;
}

.card__grid {
    display: grid;
    grid-template-columns: minmax(260px, 1fr) minmax(300px, 1.2fr);
    gap: 24px;
}

.form label {
    display: block;
    font-size: 13px;
    color: var(--ink-soft);
    margin: 14px 0 6px;
}

.form-row {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 16px;
}

.form-col {
    min-width: 0;
}

.form input,
.form textarea {
    width: 100%;
    border: none;
    border-radius: 14px;
    padding: 12px 14px;
    font-size: 15px;
    background: rgba(255, 255, 255, 0.9);
    box-shadow: inset 0 2px 6px rgba(16, 50, 84, 0.08);
    color: var(--ink);
    outline: none;
}

.form select {
    width: 100%;
    border: none;
    border-radius: 14px;
    padding: 14px 50px 14px 16px;
    font-size: 15px;
    background: linear-gradient(180deg, rgba(255, 255, 255, 0.98), rgba(235, 245, 255, 0.92));
    box-shadow: inset 0 2px 6px rgba(16, 50, 84, 0.08),
        0 10px 18px rgba(47, 115, 217, 0.12);
    color: var(--ink);
    appearance: none;
    outline: none;
    border: 1px solid rgba(122, 170, 220, 0.35);
}

.select {
    position: relative;
    border-radius: 16px;
    background: rgba(255, 255, 255, 0.5);
    padding: 4px;
    box-shadow: inset 0 1px 2px rgba(255, 255, 255, 0.6);
}

.select__chevron {
    position: absolute;
    right: 20px;
    top: 50%;
    width: 12px;
    height: 12px;
    border-right: 2px solid #1f5fb8;
    border-bottom: 2px solid #1f5fb8;
    transform: translateY(-50%) rotate(45deg);
    pointer-events: none;
    opacity: 0.9;
}

.form select:focus {
    box-shadow: inset 0 2px 6px rgba(16, 50, 84, 0.08),
        0 0 0 2px rgba(47, 115, 217, 0.25),
        0 10px 18px rgba(47, 115, 217, 0.18);
}

.actions-cell {
    text-align: center;
    white-space: nowrap;
}

.text-right {
    text-align: right;
}

.actions {
    display: inline-flex;
    gap: 8px;
    align-items: center;
    justify-content: center;
}

.icon-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 28px;
    height: 28px;
    border-radius: 9px;
    background: linear-gradient(145deg, rgba(255,255,255,0.9), rgba(220,235,255,0.8));
    color: var(--primary);
    text-decoration: none;
    font-size: 12px;
    font-weight: 700;
    box-shadow: inset 0 1px 2px rgba(255, 255, 255, 0.7),
        0 6px 14px rgba(16, 50, 84, 0.18);
    transition: transform 0.18s ease, box-shadow 0.18s ease, background 0.18s ease;
}

.icon-btn svg {
    width: 13px;
    height: 13px;
    fill: currentColor;
}

.icon-btn:hover {
    transform: translateY(-1px);
    background: linear-gradient(145deg, rgba(255,255,255,1), rgba(210,230,255,0.9));
}

.icon-btn--danger {
    color: #b71c1c;
    background: linear-gradient(145deg, rgba(255,245,245,0.95), rgba(255,220,220,0.9));
    box-shadow: inset 0 1px 2px rgba(255, 255, 255, 0.7),
        0 6px 14px rgba(120, 20, 20, 0.18);
}

.icon-btn--deliver {
    width: auto;
    min-width: 84px;
    padding: 0 10px;
    border-radius: 9px;
    font-weight: 700;
    font-size: 12px;
    color: var(--primary);
    background: linear-gradient(145deg, rgba(210,230,255,0.95), rgba(130,170,230,0.9));
}

.priority-pill {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    height: 28px;
    padding: 0 10px;
    border-radius: 9px;
    font-weight: 700;
    font-size: 12px;
    text-transform: uppercase;
    letter-spacing: 0.02em;
    box-shadow: inset 0 1px 2px rgba(255, 255, 255, 0.7),
        0 6px 14px rgba(16, 50, 84, 0.12);
}

.priority-pill--low {
    color: #1c4c8f;
    background: linear-gradient(145deg, rgba(210,230,255,0.95), rgba(130,170,230,0.9));
}

.priority-pill--high {
    color: #7a1b1b;
    background: linear-gradient(145deg, rgba(255,220,220,0.95), rgba(255,160,160,0.9));
}

.form input:focus,
.form textarea:focus {
    box-shadow: inset 0 2px 6px rgba(16, 50, 84, 0.08), 0 0 0 2px rgba(47, 115, 217, 0.25);
}

.tips {
    margin-top: 16px;
    padding: 14px;
    border-radius: 14px;
    background: rgba(47, 115, 217, 0.08);
    color: var(--ink-soft);
    font-size: 13px;
}

.status {
    margin-top: 10px;
    font-weight: 600;
    color: var(--primary);
}

.signature {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.signature__header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 12px;
    font-weight: 600;
    color: var(--ink);
}

.signature__actions {
    display: flex;
    gap: 10px;
    flex-wrap: wrap;
}

.signature__pad {
    width: 100%;
    height: 280px;
    border-radius: 18px;
    background: linear-gradient(180deg, rgba(255, 255, 255, 0.95), rgba(235, 245, 255, 0.85));
    border: 1px solid rgba(122, 170, 220, 0.45);
    box-shadow: inset 0 6px 14px rgba(16, 50, 84, 0.08);
    touch-action: none;
    -ms-touch-action: none;
    overscroll-behavior: contain;
    user-select: none;
    -webkit-user-select: none;
    -webkit-tap-highlight-color: transparent;
    position: relative;
    pointer-events: auto;
}

.card + .card {
    margin-top: 16px;
}

#signature-pad * {
    touch-action: none !important;
    pointer-events: auto !important;
}

#signature-pad canvas {
    width: 100% !important;
    height: 100% !important;
    border-radius: 18px;
    touch-action: none;
    display: block;
}

.btn {
    border: none;
    border-radius: 999px;
    padding: 10px 18px;
    font-size: 13px;
    font-weight: 700;
    letter-spacing: 0.02em;
    cursor: pointer;
    text-decoration: none;
    transition: transform 0.18s ease, box-shadow 0.18s ease, background 0.18s ease;
}

.btn:link,
.btn:visited,
.btn:hover,
.btn:active {
    text-decoration: none;
}

.btn--primary {
    background: linear-gradient(135deg, var(--primary), var(--primary-2));
    color: #fff;
    box-shadow: 0 12px 24px rgba(47, 115, 217, 0.25);
}

.btn--primary:hover {
    transform: translateY(-1px);
    box-shadow: 0 16px 30px rgba(47, 115, 217, 0.3);
}

.btn--ghost {
    background: rgba(47, 115, 217, 0.08);
    color: var(--primary);
}

.btn--ghost:hover {
    transform: translateY(-1px);
    background: rgba(47, 115, 217, 0.14);
}

.footer {
    margin-top: 26px;
    text-align: center;
    color: var(--ink-soft);
    font-size: 12px;
}

@media (max-width: 900px) {
    .card__grid {
        grid-template-columns: 1fr;
    }

    .signature__header {
        flex-direction: column;
        align-items: flex-start;
    }

    .form-row {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 600px) {
    .page {
        padding: 24px 16px 40px;
    }

    .card {
        padding: 18px;
    }

    .signature__pad {
        min-height: 220px;
    }
}

.page--center {
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    justify-content: center;
}

.module-panel {
    display: grid;
    gap: 22px;
}

.module-header {
    text-align: center;
}

.module-header h1 {
    margin: 12px 0 10px;
    font-family: "Raleway", sans-serif;
    font-size: clamp(26px, 4vw, 44px);
    line-height: 1.05;
    letter-spacing: -0.02em;
}

.module-header h1 span {
    display: block;
    font-size: clamp(18px, 3vw, 28px);
    color: var(--primary);
}

.module-header p {
    margin: 0 auto;
    max-width: 520px;
    color: var(--ink-soft);
}

.module-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
    gap: 20px;
}

.module-card {
    display: grid;
    place-items: center;
    text-align: center;
    gap: 6px;
    padding: 22px;
    border-radius: 22px;
    background: rgba(255, 255, 255, 0.82);
    border: 1px solid rgba(255, 255, 255, 0.6);
    text-decoration: none;
    color: var(--ink);
    box-shadow: 0 18px 36px rgba(8, 46, 86, 0.14);
    transition: transform 0.2s ease, box-shadow 0.2s ease;
    min-height: 160px;
}

.module-card:hover {
    transform: translateY(-2px);
    box-shadow: 0 22px 44px rgba(8, 46, 86, 0.18);
}

.module-card__badge {
    align-self: start;
    justify-self: start;
    font-size: 11px;
    font-weight: 700;
    letter-spacing: 0.12em;
    text-transform: uppercase;
    color: #1f4e85;
    background: rgba(47, 115, 217, 0.12);
    padding: 6px 12px;
    border-radius: 999px;
}

.module-card__title {
    font-size: 22px;
    font-weight: 700;
}

.module-card__desc {
    color: var(--ink-soft);
    font-size: 13px;
    line-height: 1.5;
}

.module-card--disabled {
    opacity: 0.7;
    filter: grayscale(0.2);
    cursor: not-allowed;
}

.module-card--disabled:hover {
    transform: none;
    box-shadow: 0 18px 36px rgba(8, 46, 86, 0.14);
}

.module-actions {
    display: flex;
    justify-content: center;
}



