:root {
    --g: #1E3A37;
    --gl: #2A504C;
    --gp: #E8F0EF;
    --y: #F2F26E;
    --ys: rgba(242, 242, 110, .18);
    --ym: #E8E854;
    --bg: #fff;
    --sf: #FAFAF8;
    --sf2: #F4F4F0;
    --tx: #1A1D23;
    --ts: #4A4E58;
    --tm: #8E939B;
    --ln: #E5E5E2;
    --ls: #F0F0EC;
    --ok: #2F8F4F;
    --wr: #B86E1A;
    --br: #c0392b;
}

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

html, body {
    height: 100%;
}

body {
    font-family: 'Urbanist', system-ui, sans-serif;
    color: var(--tx);
    line-height: 1.55;
    -webkit-font-smoothing: antialiased;
    background: var(--sf);
    font-weight: 300;
}

.nv-app {
    min-height: 100vh;
    display: flex;
    flex-direction: column;
}

.nv-toolbar {
    background: var(--bg);
    border-bottom: 1px solid var(--ln);
    padding: 14px 32px;
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.nv-toolbar__left, .nv-toolbar__right {
    display: flex;
    align-items: center;
    gap: 10px;
}

.nv-logo {
    display: flex;
    align-items: baseline;
    gap: 10px;
    text-decoration: none;
    color: var(--tx);
}

.nv-logo__text {
    font-size: 1.3rem;
    font-weight: 700;
    letter-spacing: .08em;
    color: var(--g);
}

.nv-logo__text--lg {
    font-size: 2rem;
}

.nv-logo__sub {
    font-size: .78rem;
    color: var(--tm);
    font-weight: 400;
    letter-spacing: .05em;
    text-transform: uppercase;
}

.nv-logo__tagline {
    display: block;
    font-size: .68rem;
    color: var(--tm);
    letter-spacing: .18em;
    text-transform: uppercase;
    font-weight: 400;
    margin-top: 4px;
}

.nv-main {
    flex: 1;
}

.nv-eyebrow {
    display: inline-block;
    font-size: .74rem;
    letter-spacing: .18em;
    text-transform: uppercase;
    color: var(--tm);
    font-weight: 500;
}

.nv-btn {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 10px 22px;
    font-family: inherit;
    font-size: .88rem;
    font-weight: 500;
    cursor: pointer;
    transition: all .15s;
    border: none;
    line-height: 1.4;
    text-decoration: none;
}

.nv-btn:disabled {
    opacity: .4;
    cursor: not-allowed;
}

.nv-btn--primary {
    background: var(--g);
    color: #F5F5F3;
}

.nv-btn--primary:hover:not(:disabled) {
    background: var(--gl);
}

.nv-btn--ghost {
    background: transparent;
    border: 1px solid var(--ln);
    color: var(--ts);
}

.nv-btn--ghost:hover:not(:disabled) {
    border-color: var(--tx);
    color: var(--tx);
}

.nv-btn--secondary {
    background: transparent;
    border: 1px solid var(--g);
    color: var(--g);
}

.nv-btn--secondary:hover:not(:disabled) {
    background: var(--g);
    color: #F5F5F3;
}

.nv-btn--full {
    width: 100%;
    justify-content: center;
}

.nv-btn--back {
    border: none;
    padding-left: 0;
}

.nv-badge {
    display: inline-block;
    font-size: .7rem;
    font-weight: 500;
    letter-spacing: .08em;
    text-transform: uppercase;
    color: var(--tm);
    background: var(--sf2);
    padding: 2px 8px;
    margin-left: 8px;
}

.nv-segmented {
    display: inline-flex;
    background: var(--sf2);
    border: 1px solid var(--ln);
    padding: 4px;
    gap: 4px;
}

.nv-segmented__option {
    border: none;
    background: transparent;
    padding: 8px 18px;
    font-family: inherit;
    font-size: .88rem;
    color: var(--ts);
    cursor: pointer;
    transition: all .15s;
}

.nv-segmented__option--active {
    background: var(--g);
    color: #F5F5F3;
}

.nv-dach-card {
    border: 1px solid var(--ln);
    padding: 18px 20px;
    margin-top: 12px;
    background: var(--sf2);
}

.nv-dach-card__title {
    font-size: .82rem;
    font-weight: 500;
    letter-spacing: .04em;
    text-transform: uppercase;
    color: var(--tm);
    margin-bottom: 12px;
}

.nv-lageplan {
    margin-top: 12px;
}

.nv-lageplan__drop {
    display: flex;
    align-items: center;
    justify-content: center;
    border: 1.5px dashed var(--ln);
    background: var(--sf2);
    padding: 28px 24px;
    cursor: pointer;
    transition: border-color .15s;
}

.nv-lageplan__drop:hover {
    border-color: var(--g);
}

.nv-lageplan__drop input {
    display: none;
}

.nv-lageplan__hint {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 4px;
    text-align: center;
}

.nv-lageplan__hint strong {
    font-weight: 500;
    color: var(--tx);
}

.nv-lageplan__hint span {
    font-size: .85rem;
    color: var(--ts);
}

.nv-lageplan__preview {
    border: 1px solid var(--ln);
    padding: 12px;
    background: var(--sf2);
}

.nv-lageplan__preview img {
    width: 100%;
    max-height: 360px;
    object-fit: contain;
    display: block;
    background: #fff;
}

.nv-lageplan__meta {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-top: 10px;
    font-size: .85rem;
    color: var(--ts);
}

.nv-btn--small {
    padding: 6px 14px;
    font-size: .82rem;
}

.nv-attachments-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(160px, 1fr));
    gap: 12px;
    margin-top: 16px;
}

.nv-attachment-tile {
    border: 1px solid var(--ln);
    background: var(--sf2);
    padding: 8px;
    display: flex;
    flex-direction: column;
}

.nv-attachment-tile img {
    width: 100%;
    height: 110px;
    object-fit: cover;
    background: #fff;
    display: block;
}

.nv-attachment-tile__meta {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-top: 8px;
    gap: 8px;
}

.nv-attachment-tile__meta span {
    font-size: .76rem;
    color: var(--ts);
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    flex: 1;
}

.nv-pdf-tile {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 18px 20px;
    background: #fff;
    border: 1px solid var(--ln);
    color: var(--ts);
}

.nv-pdf-tile span {
    font-weight: 500;
    color: var(--tx);
}

.nv-textarea {
    resize: vertical;
    min-height: 120px;
    font-family: inherit;
    line-height: 1.5;
}

.nv-field__hint {
    display: block;
    font-size: .8rem;
    color: var(--tm);
    margin-top: 6px;
}

.nv-field__warning {
    display: block;
    font-size: .82rem;
    font-weight: 600;
    letter-spacing: .04em;
    color: #c0392b;
    margin-top: 8px;
    text-transform: uppercase;
}

.nv-segmented__option--urgent {
    color: #c0392b;
}

.nv-segmented__option--urgent.nv-segmented__option--active {
    background: #c0392b;
    color: #fff;
}

.nv-doc-option__hint {
    display: block;
    font-size: .82rem;
    color: var(--ts);
    margin-top: 4px;
}

.nv-loading-overlay {
    position: fixed;
    inset: 0;
    background: rgba(20, 20, 18, 0.55);
    backdrop-filter: blur(2px);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 1000;
    cursor: wait;
}

.nv-loading-overlay__box {
    background: var(--bg);
    border: 1px solid var(--ln);
    padding: 32px 40px;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 18px;
    min-width: 240px;
}

.nv-loading-overlay__text {
    font-size: .92rem;
    color: var(--ts);
    letter-spacing: .01em;
}

.nv-spinner {
    width: 36px;
    height: 36px;
    border: 3px solid var(--ln);
    border-top-color: var(--g);
    border-radius: 50%;
    animation: nv-spin 0.9s linear infinite;
}

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

/* LOGIN */

.nv-login {
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    background: var(--bg);
    position: relative;
    overflow: hidden;
}

.nv-login::after {
    content: "";
    position: absolute;
    inset: 0;
    background: radial-gradient(ellipse at 50% 120%, var(--ys) 0%, transparent 55%);
    pointer-events: none;
}

.nv-login__card {
    position: relative;
    z-index: 1;
    width: 100%;
    max-width: 380px;
    padding: 48px 36px;
    text-align: center;
}

.nv-login__logo {
    margin-bottom: 40px;
}

.nv-login__title {
    font-size: 1.6rem;
    font-weight: 400;
    margin-bottom: 8px;
    letter-spacing: -.01em;
}

.nv-login__desc {
    color: var(--ts);
    font-size: .92rem;
    margin-bottom: 32px;
}

.nv-pin-group {
    display: flex;
    gap: 12px;
    justify-content: center;
    margin-bottom: 28px;
}

.nv-pin-input {
    width: 56px;
    height: 64px;
    border: 1px solid var(--ln);
    background: var(--bg);
    text-align: center;
    font-family: inherit;
    font-size: 1.8rem;
    font-weight: 600;
    color: var(--tx);
    outline: none;
    transition: border-color .15s;
    caret-color: transparent;
}

.nv-pin-input:focus {
    border-color: var(--g);
    box-shadow: 0 0 0 3px var(--ys);
}

.nv-pin-input--error {
    border-color: var(--br);
}

.nv-login__error {
    color: var(--br);
    font-size: .85rem;
    margin-bottom: 16px;
    font-weight: 400;
}

/* DASHBOARD */

.nv-dashboard {
    max-width: 900px;
    margin: 0 auto;
    padding: 60px 32px;
}

.nv-dashboard__header {
    text-align: center;
    margin-bottom: 48px;
}

.nv-dashboard__title {
    font-size: clamp(1.8rem, 4vw, 2.6rem);
    font-weight: 400;
    letter-spacing: -.02em;
    margin: 16px 0 12px;
}

.nv-dashboard__desc {
    color: var(--ts);
    font-size: 1rem;
    font-weight: 300;
}

.nv-category-grid {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.nv-category-card {
    display: flex;
    align-items: center;
    gap: 20px;
    padding: 24px 28px;
    background: var(--bg);
    border: 1px solid var(--ln);
    cursor: pointer;
    transition: all .15s;
    text-align: left;
    font-family: inherit;
    width: 100%;
    position: relative;
}

.nv-category-card--active:hover {
    border-color: var(--g);
}

.nv-category-card--disabled {
    opacity: .5;
    cursor: default;
}

.nv-category-card__icon {
    width: 44px;
    height: 44px;
    flex-shrink: 0;
    background: var(--gp);
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--g);
}

.nv-category-card--active .nv-category-card__icon {
    background: var(--g);
    color: var(--y);
}

.nv-category-card__icon svg {
    width: 22px;
    height: 22px;
}

.nv-category-card__content {
    flex: 1;
}

.nv-category-card__content h3 {
    font-size: 1rem;
    font-weight: 500;
    margin-bottom: 2px;
    color: var(--tx);
}

.nv-category-card__content p {
    font-size: .85rem;
    color: var(--tm);
    font-weight: 300;
}

.nv-category-card__arrow {
    color: var(--tm);
}

.nv-category-card__arrow svg {
    width: 18px;
    height: 18px;
}

.nv-category-card__badge {
    position: absolute;
    top: -1px;
    right: -1px;
    background: var(--sf2);
    color: var(--tm);
    font-size: .68rem;
    font-weight: 500;
    letter-spacing: .1em;
    text-transform: uppercase;
    padding: 5px 12px;
}

/* CREATOR */

.nv-creator {
    max-width: 1100px;
    margin: 0 auto;
    padding: 32px;
}

.nv-creator__header {
    margin-bottom: 32px;
}

.nv-creator__title {
    font-size: 1.8rem;
    font-weight: 400;
    letter-spacing: -.015em;
    margin-top: 12px;
}

.nv-creator__grid {
    display: grid;
    grid-template-columns: 260px 1fr;
    gap: 32px;
    align-items: start;
}

@media (max-width: 860px) {
    .nv-creator__grid {
        grid-template-columns: 1fr;
    }
}

.nv-panel {
    background: var(--bg);
    border: 1px solid var(--ln);
    padding: 28px;
    position: relative;
}

.nv-panel--sticky {
    position: sticky;
    top: 80px;
}

@media (max-width: 860px) {
    .nv-panel--sticky {
        position: static;
    }
}

.nv-panel__tag {
    position: absolute;
    top: -1px;
    left: -1px;
    background: var(--g);
    color: var(--y);
    padding: 6px 14px;
    font-size: .68rem;
    font-weight: 500;
    letter-spacing: .12em;
    text-transform: uppercase;
}

.nv-progress {
    margin-top: 32px;
    display: flex;
    flex-direction: column;
    gap: 0;
}

.nv-progress__step {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 14px 0;
    border-bottom: 1px solid var(--ls);
    font-size: .88rem;
    color: var(--tm);
    font-weight: 300;
}

.nv-progress__step:last-child {
    border-bottom: none;
}

.nv-progress__step--active {
    color: var(--tx);
    font-weight: 500;
}

.nv-progress__dot {
    width: 28px;
    height: 28px;
    display: flex;
    align-items: center;
    justify-content: center;
    border: 1px solid var(--ln);
    font-size: .78rem;
    font-weight: 500;
    color: var(--tm);
    flex-shrink: 0;
}

.nv-progress__step--active .nv-progress__dot {
    background: var(--g);
    color: var(--y);
    border-color: var(--g);
}

.nv-progress__step--done .nv-progress__dot {
    background: var(--gp);
    color: var(--g);
    border-color: var(--gp);
}

/* SECTIONS */

.nv-section {
    background: var(--bg);
    border: 1px solid var(--ln);
    padding: 36px;
}

.nv-section__title {
    font-size: 1.3rem;
    font-weight: 400;
    letter-spacing: -.01em;
    margin-bottom: 8px;
}

.nv-section__subtitle {
    font-size: 1rem;
    font-weight: 500;
    color: var(--ts);
    margin: 28px 0 16px;
    padding-top: 20px;
    border-top: 1px solid var(--ls);
}

.nv-section__desc {
    color: var(--ts);
    font-size: .92rem;
    margin-bottom: 28px;
    font-weight: 300;
}

/* DOCUMENT SELECT */

.nv-doc-select {
    display: flex;
    flex-direction: column;
    gap: 8px;
    margin-bottom: 28px;
}

.nv-doc-option {
    display: flex;
    align-items: center;
    gap: 14px;
    padding: 16px 20px;
    background: var(--bg);
    border: 1px solid var(--ln);
    cursor: pointer;
    transition: all .15s;
    font-family: inherit;
    font-size: .92rem;
    color: var(--tx);
    text-align: left;
    width: 100%;
}

.nv-doc-option:hover:not(:disabled) {
    border-color: var(--g);
}

.nv-doc-option--selected {
    border-color: var(--g);
    background: var(--gp);
}

.nv-doc-option--disabled {
    opacity: .45;
    cursor: not-allowed;
}

.nv-doc-option__check {
    width: 22px;
    height: 22px;
    border: 1.5px solid var(--ln);
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    color: var(--g);
}

.nv-doc-option--selected .nv-doc-option__check {
    background: var(--g);
    border-color: var(--g);
    color: var(--y);
}

.nv-doc-option__check svg {
    width: 14px;
    height: 14px;
}

.nv-doc-option__info {
    display: flex;
    align-items: center;
    gap: 4px;
}

.nv-doc-option__info strong {
    font-weight: 500;
}

/* FORM */

.nv-form-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 20px;
}

@media (max-width: 600px) {
    .nv-form-grid {
        grid-template-columns: 1fr;
    }
}

.nv-field {
    display: flex;
    flex-direction: column;
    gap: 6px;
}

.nv-field--full {
    grid-column: 1 / -1;
}

.nv-field__label {
    font-size: .85rem;
    font-weight: 400;
    color: var(--tx);
}

.nv-input {
    width: 100%;
    padding: 11px 14px;
    border: 1px solid var(--ln);
    background: var(--bg);
    font-family: inherit;
    font-size: .92rem;
    font-weight: 400;
    color: var(--tx);
    outline: none;
    transition: border-color .15s;
}

.nv-input:focus {
    border-color: var(--g);
}

.nv-input::placeholder {
    color: var(--tm);
    font-weight: 300;
}

.nv-input--error {
    border-color: #c0392b;
    background: #fdf3f2;
}

.nv-input--error:focus {
    border-color: #c0392b;
    box-shadow: 0 0 0 2px rgba(192, 57, 43, .15);
}

.nv-field__error {
    display: block;
    font-size: .82rem;
    font-weight: 500;
    color: #c0392b;
    margin-top: 6px;
}

.nv-lageplan__drop--error {
    border-color: #c0392b;
    background: #fdf3f2;
}

.nv-form-actions {
    display: flex;
    gap: 12px;
    margin-top: 32px;
    justify-content: flex-end;
}

.validation-message {
    font-size: .78rem;
    color: var(--br);
    font-weight: 400;
}

/* SUMMARY */

.nv-summary {
    background: var(--sf);
    padding: 20px 24px;
    border: 1px solid var(--ln);
}

.nv-summary__row {
    display: flex;
    justify-content: space-between;
    padding: 8px 0;
    font-size: .88rem;
    border-bottom: 1px solid var(--ls);
}

.nv-summary__row:last-child {
    border-bottom: none;
}

.nv-summary__label {
    color: var(--tm);
    font-weight: 400;
}

/* EMAIL PREVIEW */

.nv-email-preview {
    margin-top: 24px;
    border: 1px solid var(--ln);
    background: var(--bg);
}

.nv-email-preview__header {
    padding: 14px 20px;
    border-bottom: 1px solid var(--ln);
    background: var(--sf);
}

.nv-email-preview__content {
    padding: 20px 24px;
}

.nv-email-preview__row {
    font-size: .88rem;
    padding: 4px 0;
    color: var(--ts);
}

.nv-email-preview__row strong {
    font-weight: 500;
    color: var(--tx);
    margin-right: 8px;
}

.nv-email-preview__divider {
    height: 1px;
    background: var(--ln);
    margin: 14px 0;
}

.nv-email-preview__body {
    font-size: .88rem;
    color: var(--ts);
    line-height: 1.7;
    font-weight: 300;
}

.nv-email-preview__body p {
    margin-bottom: 2px;
}

.nv-email-preview__attachments {
    margin-top: 16px;
    padding-top: 14px;
    border-top: 1px solid var(--ln);
    font-size: .85rem;
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    align-items: center;
}

.nv-email-preview__attachments strong {
    font-weight: 500;
    margin-right: 4px;
}

.nv-attachment {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    background: var(--sf);
    border: 1px solid var(--ln);
    padding: 4px 10px;
    font-size: .78rem;
    color: var(--ts);
    font-weight: 400;
}

/* STATUS BANNERS */

.nv-success-banner {
    margin-top: 20px;
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 16px 20px;
    background: #e8f5e9;
    border-left: 4px solid var(--ok);
    font-size: .9rem;
    color: var(--ok);
    font-weight: 500;
}

.nv-error-banner {
    margin-top: 20px;
    padding: 16px 20px;
    background: #fdecea;
    border-left: 4px solid var(--br);
    font-size: .9rem;
    color: var(--br);
    font-weight: 400;
}
