@import url('https://fonts.googleapis.com/css2?family=Manrope:wght@400;500;600;700;800&family=Forum&display=swap');

:root {
    --bg:       #F4F8FC;
    --bg2:      #EAF2FA;
    --surface:  #FFFFFF;
    --ink:      #0E2540;
    --inkSoft:  #44617D;
    --inkMuted: #93A3B8;
    --rule:     #DCE6F0;
    --ruleSoft: #EAF0F6;
    --blueSoft: #DCE9F2;
    --blue:     #A8C8E1;
    --blueDeep: #2A6FB5;
    --navy:     #0E2540;
    --accent:   #E2C385;
}

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

body {
    font-family: 'Manrope', system-ui, sans-serif;
    color: var(--ink);
    background-color: var(--bg);
}

/* ── Navbar ─────────────────────────────────────────────────── */
.navbar {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 1.2rem 2rem;
    background-color: var(--surface);
    box-shadow: 0 1px 0 rgba(14, 37, 64, 0.06);
    position: sticky;
    top: 0;
    z-index: 900;
    transition: transform 0.25s ease;
}

.navbar.nav-hidden {
    transform: translateY(-100%);
}

.navbar-menu {
    display: flex;
    align-items: center;
    gap: 1rem;
}

.logo {
    font-family: 'Forum', serif;
    font-size: 2rem;
    color: var(--ink);
    text-decoration: none;
    display: flex;
    align-items: center;
    gap: 0.6rem;
    letter-spacing: -0.005em;
}

.logo-icon {
    height: 2rem;
    width: auto;
}

.sign-in-btn {
    padding: 12px 22px;
    background-color: var(--navy);
    color: var(--surface);
    border: none;
    border-radius: 10px;
    cursor: pointer;
    font-size: 1rem;
    font-weight: 600;
    transition: background-color 0.2s;
    text-decoration: none;
}

.sign-in-btn:hover {
    background-color: #1a3a5c;
}

/* ── Hero / Landing ─────────────────────────────────────────── */
.hero-section {
    display: flex;
    align-items: center;
    gap: 3rem;
    padding: 5rem 3rem 4rem;
    max-width: 1200px;
    margin: 0 auto;
}

.hero-left {
    flex: 1 1 0;
    min-width: 0;
}

.hero-right {
    flex-shrink: 0;
    width: 400px;
}

/* Eyebrow pill — shared utility used on landing, preferences, etc. */
.eyebrow-pill {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    background: var(--blueSoft);
    color: var(--blueDeep);
    border-radius: 999px;
    padding: 5px 14px;
    font-size: 11px;
    font-weight: 700;
    letter-spacing: 0.14em;
    text-transform: uppercase;
    margin-bottom: 1.5rem;
}

.eyebrow-dot {
    width: 6px;
    height: 6px;
    border-radius: 50%;
    background: var(--blueDeep);
    flex-shrink: 0;
}

/* Hero headline */
.hero-headline {
    font-family: 'Forum', serif;
    font-size: 4rem;
    line-height: 1.15;
    color: var(--ink);
    letter-spacing: -0.005em;
    margin-bottom: 1.25rem;
}

.hero-headline .highlight {
    color: var(--blueDeep);
}

.hero-subtitle {
    font-size: 1.05rem;
    color: var(--inkSoft);
    line-height: 1.6;
    margin-bottom: 2rem;
    max-width: 460px;
}

/* Planning form card */
.planning-form {
    display: flex;
    align-items: stretch;
    background: var(--surface);
    border-radius: 14px;
    box-shadow: 0 8px 24px rgba(14, 37, 64, 0.06);
    border: 1px solid var(--rule);
    padding: 6px 6px 6px 0;
    margin-bottom: 2rem;
    gap: 0;
}

.planning-field {
    display: flex;
    flex-direction: column;
    gap: 2px;
    padding: 10px 16px;
    flex: 1 1 0;
    min-width: 0;
}

.planning-field-days {
    flex: 0 0 auto;
    border-left: 1px solid var(--rule);
}

.planning-label {
    font-size: 10px;
    font-weight: 700;
    letter-spacing: 0.14em;
    text-transform: uppercase;
    color: var(--blueDeep);
    line-height: 1;
}

.planning-input-wrap {
    display: flex;
    align-items: center;
    gap: 6px;
}

.planning-pin {
    color: var(--inkMuted);
    font-size: 13px;
    flex-shrink: 0;
}

.planning-form input[type="text"],
.planning-form input[type="number"] {
    border: none;
    outline: none;
    background: transparent;
    font-size: 15px;
    font-weight: 500;
    color: var(--ink);
    font-family: inherit;
    width: 100%;
    padding: 2px 0;
}

.planning-form input::placeholder {
    color: var(--inkMuted);
    font-weight: 400;
}

.planning-form input[type="number"] {
    width: 60px;
}

.planning-form button {
    padding: 12px 20px;
    background: var(--navy);
    color: var(--surface);
    border: none;
    border-radius: 10px;
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    white-space: nowrap;
    align-self: center;
    margin-left: 4px;
    flex-shrink: 0;
    transition: background-color 0.2s;
    font-family: inherit;
}

.planning-form button:disabled {
    background: var(--inkMuted);
    cursor: not-allowed;
}

.planning-form button:not(:disabled):hover {
    background: #1a3a5c;
}

.planning-error {
    display: none;
    margin: -1rem 0 1.5rem;
    font-size: 13px;
    color: #dc2626;
}

.planning-error.visible {
    display: block;
}

.planning-form input.planning-input-error {
    color: #dc2626;
}

/* Social proof */
.hero-proof {
    display: flex;
    align-items: center;
    gap: 12px;
}

.proof-avatars {
    display: flex;
    align-items: center;
}

.proof-avatar {
    width: 28px;
    height: 28px;
    border-radius: 50%;
    border: 2px solid var(--surface);
    flex-shrink: 0;
}

.proof-avatar + .proof-avatar { margin-left: -8px; }
.proof-a1 { background: var(--blue); }
.proof-a2 { background: var(--navy); }
.proof-a3 { background: var(--accent); }
.proof-a4 { background: var(--blueSoft); border-color: var(--rule); }

.proof-text {
    font-size: 13px;
    color: var(--inkSoft);
}

.proof-text strong { color: var(--ink); }

/* Hero photo cards */
.hero-photos {
    position: relative;
    height: 500px;
}

.hero-pin-card {
    position: absolute;
    top: 42%;
    left: -24px;
    z-index: 10;
    background: var(--surface);
    border-radius: 12px;
    padding: 10px 14px;
    box-shadow: 0 6px 16px rgba(14, 37, 64, 0.10);
    display: flex;
    flex-direction: column;
    gap: 2px;
    white-space: nowrap;
}

.hero-pin-label {
    font-size: 10px;
    font-weight: 700;
    color: var(--inkMuted);
    text-transform: uppercase;
    letter-spacing: 0.10em;
}

.hero-pin-place {
    font-size: 14px;
    font-weight: 600;
    color: var(--ink);
}

.photo-card {
    position: absolute;
    background: var(--surface);
    border-radius: 16px;
    padding: 8px 8px 20px;
    box-shadow: 0 24px 60px rgba(14, 37, 64, 0.10);
    overflow: hidden;
}

.photo-card-img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
    border-radius: 10px;
}

.photo-card-big {
    width: 270px;
    height: 340px;
    right: 0;
    top: 20px;
    transform: rotate(2.5deg);
}

.photo-card-small {
    width: 230px;
    height: 160px;
    left: 0;
    bottom: 30px;
    transform: rotate(-2deg);
}

/* ── Footer ─────────────────────────────────────────────────── */
footer {
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 1.5rem 2rem;
    border-top: 1px solid var(--rule);
    background: transparent;
}

.footer-text {
    font-size: 13px;
    color: var(--inkMuted);
}

/* ── Auth split-card layout (login + register) ───────────────── */
.auth-page-wrap {
    display: flex;
    align-items: center;
    justify-content: center;
    min-height: calc(100vh - 100px);
    padding: 2rem;
}

.auth-card {
    display: flex;
    width: 100%;
    max-width: 920px;
    min-height: 540px;
    border-radius: 18px;
    overflow: hidden;
    box-shadow: 0 24px 60px rgba(14, 37, 64, 0.10);
}

.auth-form-side {
    flex: 0 0 50%;
    background: var(--surface);
    padding: 48px 44px;
    display: flex;
    flex-direction: column;
    justify-content: center;
    gap: 0;
}

.auth-image-side {
    flex: 0 0 50%;
    position: relative;
    overflow: hidden;
    background: var(--bg2);
}

.auth-image-side img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: center;
    display: block;
}

/* Auth form content */
.auth-eyebrow {
    font-size: 11px;
    font-weight: 700;
    letter-spacing: 0.14em;
    text-transform: uppercase;
    color: var(--blueDeep);
    margin-bottom: 0.6rem;
}

.auth-heading {
    font-family: 'Forum', serif;
    font-size: 2.4rem;
    color: var(--ink);
    letter-spacing: -0.005em;
    margin-bottom: 2rem;
    line-height: 1.1;
}

.auth-form-group {
    display: flex;
    flex-direction: column;
    gap: 4px;
    margin-bottom: 0.6rem;
}

.auth-form-group label {
    font-size: 13px;
    font-weight: 600;
    color: var(--ink);
}

.auth-form-group input {
    padding: 12px 14px;
    border: 1px solid var(--rule);
    border-radius: 10px;
    font-size: 15px;
    color: var(--ink);
    background: var(--surface);
    font-family: inherit;
    transition: border-color 0.15s ease;
}

.auth-form-group input:focus {
    outline: none;
    border-color: var(--blueDeep);
}

.auth-submit-btn {
    width: 100%;
    padding: 14px;
    background: var(--navy);
    color: var(--surface);
    border: none;
    border-radius: 10px;
    font-size: 15px;
    font-weight: 600;
    cursor: pointer;
    font-family: inherit;
    transition: background-color 0.15s ease;
    margin-top: 0.5rem;
    margin-bottom: 1.2rem;
}

.auth-submit-btn:hover {
    background: #1a3a5c;
}

.auth-footer-text {
    font-size: 14px;
    color: var(--inkSoft);
    text-align: center;
}

.auth-subtle {
    font-size: 14px;
    color: var(--inkSoft);
    line-height: 1.5;
    margin-bottom: 1.4rem;
}

.auth-forgot-link {
    display: block;
    margin-top: 0.4rem;
    margin-bottom: 1rem;
    font-size: 14px;
    color: var(--blueDeep);
    text-decoration: underline;
    text-align: center;
}

.auth-forgot-link:hover {
    text-decoration: none;
}

.auth-footer-text a {
    color: var(--blueDeep);
    font-weight: 600;
    text-decoration: none;
}

.auth-footer-text a:hover {
    text-decoration: underline;
}

.auth-alert {
    padding: 12px 14px;
    border-radius: 10px;
    margin-bottom: 1.2rem;
    font-size: 14px;
}

.auth-alert-danger {
    background-color: #f8d7da;
    color: #721c24;
    border: 1px solid #f5c6cb;
}

.auth-alert-success {
    background-color: #d4edda;
    color: #155724;
    border: 1px solid #c3e6cb;
}

.auth-text-danger {
    font-size: 12px;
    color: #7A1E1E;
    margin-top: 0;
    line-height: 1.4;
    min-height: 1.4em;
}

.auth-text-danger.is-info {
    color: #6b7280;
}

.auth-text-danger:empty::before {
    content: "";
    display: inline-block;
}

.auth-text-danger a {
    color: inherit;
    text-decoration: underline;
    font-weight: 500;
}

.auth-form-group input.field-invalid {
    border-color: #7A1E1E;
}

.auth-form-group input.field-invalid:focus {
    border-color: #7A1E1E;
}

.auth-submit-btn:disabled {
    opacity: 0.55;
    cursor: not-allowed;
}

.password-checklist {
    list-style: none;
    padding: 0;
    margin: 4px 0 0 0;
    font-size: 12px;
    color: #6b7280;
    line-height: 1.5;
}

.password-checklist li {
    display: flex;
    align-items: flex-start;
    gap: 6px;
    padding: 1px 0;
    transition: color 0.15s ease;
}

.password-checklist li::before {
    content: "○";
    font-size: 12px;
    color: #9ca3af;
    width: 14px;
    flex-shrink: 0;
    display: inline-block;
    text-align: center;
    line-height: 1.5;
}

.password-checklist li.met {
    color: #16a34a;
}

.password-checklist li.met::before {
    content: "✓";
    color: #16a34a;
    font-weight: 700;
}

/* ── Profile menu ───────────────────────────────────────────── */
.profile-menu {
    position: relative;
    display: flex;
    align-items: center;
}

.profile-trigger {
    background: transparent;
    border: none;
    cursor: pointer;
    padding: 4px;
    display: flex;
    align-items: center;
    border-radius: 50%;
    transition: background-color 0.15s ease;
}

.profile-trigger:hover {
    background: var(--bg2);
}

.profile-icon {
    height: 2rem;
    width: 2rem;
    border-radius: 50%;
    display: block;
}

.profile-dropdown {
    position: absolute;
    right: 0;
    top: calc(100% + 8px);
    width: 320px;
    background: var(--surface);
    border-radius: 12px;
    box-shadow: 0 8px 24px rgba(14, 37, 64, 0.06);
    padding: 16px;
    display: flex;
    flex-direction: column;
    gap: 8px;
    z-index: 950;
}

.profile-dropdown[hidden] {
    display: none;
}

.profile-field-label {
    font-size: 12px;
    font-weight: 600;
    color: var(--inkSoft);
    margin-top: 4px;
}

.profile-input {
    width: 100%;
    box-sizing: border-box;
    padding: 10px 12px;
    border: 1px solid var(--rule);
    border-radius: 8px;
    font-size: 14px;
    color: var(--ink);
    font-family: inherit;
    background: var(--surface);
}

.profile-input:focus {
    outline: none;
    border-color: var(--blueDeep);
}

.profile-input[readonly] {
    background: var(--bg);
    color: var(--inkSoft);
}

.profile-name-row {
    display: flex;
    gap: 8px;
}

.profile-name-row .profile-input {
    flex: 1;
}

.profile-update-btn {
    background: var(--navy);
    color: var(--surface);
    border: none;
    border-radius: 8px;
    padding: 0 14px;
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    transition: background-color 0.15s ease;
}

.profile-update-btn:hover:not(:disabled) {
    background: #1a3a5c;
}

.profile-update-btn:disabled {
    background: var(--inkMuted);
    cursor: not-allowed;
}

.profile-actions {
    display: flex;
    gap: 8px;
    margin-top: 8px;
}

.profile-action-btn {
    flex: 1;
    padding: 10px;
    border-radius: 8px;
    border: 1px solid transparent;
    cursor: pointer;
    font-size: 14px;
    font-weight: 600;
    color: var(--surface);
    transition: background-color 0.15s ease;
}

.profile-action-btn.logout {
    background: #a73c53;
}

.profile-action-btn.logout:hover {
    background: #8a2f43;
}

.profile-action-btn.delete {
    background: #7f1d1d;
}

.profile-action-btn.delete:hover {
    background: #5f1414;
}

/* ── Modal (global) ─────────────────────────────────────────── */
.modal-backdrop {
    position: fixed;
    inset: 0;
    background: rgba(14, 37, 64, 0.45);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 1000;
    padding: 16px;
}

.modal-backdrop[hidden] {
    display: none;
}

.modal-card {
    background: var(--surface);
    border-radius: 16px;
    width: 100%;
    max-width: 480px;
    box-shadow: 0 24px 60px rgba(14, 37, 64, 0.10);
    overflow: hidden;
    display: flex;
    flex-direction: column;
}

.modal-header {
    padding: 20px 24px 8px;
}

.modal-header h3 {
    margin: 0;
    font-size: 18px;
    font-weight: 700;
    color: var(--ink);
    letter-spacing: -0.025em;
}

.modal-body {
    padding: 8px 24px 8px;
    color: var(--inkSoft);
    font-size: 14px;
    line-height: 1.5;
}

.modal-body p {
    margin: 0;
}

.modal-card .modal-footer {
    display: flex;
    flex-direction: row;
    align-items: stretch;
    gap: 12px;
    padding: 16px 24px 20px;
}

.modal-btn {
    flex: 1;
    padding: 12px 22px;
    border-radius: 10px;
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    border: 1px solid transparent;
    transition: background-color 0.15s ease, border-color 0.15s ease;
    font-family: inherit;
}

.modal-btn-secondary {
    background: var(--surface);
    border-color: var(--rule);
    color: var(--ink);
}

.modal-btn-secondary:hover {
    background: var(--bg);
}

.modal-btn-primary {
    background: var(--navy);
    color: var(--surface);
}

.modal-btn-primary:hover:not(:disabled) {
    background: #1a3a5c;
}

.modal-btn-danger-strong {
    background: #7f1d1d;
    color: var(--surface);
    border-color: #7f1d1d;
}

.modal-btn-danger-strong:hover:not(:disabled) {
    background: #5f1414;
    border-color: #5f1414;
}

.nav-modal-form {
    flex: 1;
    display: flex;
}

.nav-modal-submit {
    width: 100%;
}

/* ── My Trips dropdown ─────────────────────────────────────── */
.trips-menu {
    position: relative;
    display: flex;
    align-items: center;
}

.trips-trigger,
.preferences-link {
    background: transparent;
    border: none;
    cursor: pointer;
    color: var(--ink);
    font-size: 18px;
    font-weight: bold;
    font-family: inherit;
    line-height: 1;
    text-decoration: none;
    padding: 4px 8px;
    border-radius: 8px;
    transition: background-color 0.15s ease;
    display: flex;
    align-items: center;
}

.trips-trigger:hover,
.preferences-link:hover {
    background: var(--bg2);
}

.trips-dropdown {
    position: absolute;
    right: 0;
    top: 100%;
    width: 320px;
    background: var(--surface);
    border-radius: 12px;
    box-shadow: 0 8px 24px rgba(14, 37, 64, 0.06);
    padding: 8px;
    z-index: 950;
    overflow: visible;
}

.trips-dropdown[hidden] {
    display: none;
}

.trips-dropdown-list {
    list-style: none;
    padding: 0;
    margin: 0;
    display: flex;
    flex-direction: column;
    gap: 2px;
    max-height: 400px;
    overflow-y: auto;
}

.trips-dropdown-list .trip-days {
    color: var(--inkSoft);
    font-weight: 500;
    font-size: 13px;
    flex-shrink: 0;
}

.trip-item {
    position: relative;
}

.trip-item-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 8px;
    padding: 10px 12px 10px 36px;
    color: var(--ink);
    text-decoration: none;
    border-radius: 8px;
    font-size: 14px;
    font-weight: 600;
    transition: background-color 0.15s ease;
    cursor: pointer;
}

.trip-item-row:hover,
.trip-item-row.is-active {
    background: var(--bg2);
}

.trip-delete-btn {
    position: absolute;
    left: 8px;
    top: 50%;
    transform: translateY(-50%);
    width: 24px;
    height: 24px;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 0;
    background: transparent;
    border: none;
    border-radius: 6px;
    color: var(--inkSoft);
    font-size: 13px;
    line-height: 1;
    cursor: pointer;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.15s ease, color 0.15s ease, background-color 0.15s ease;
    z-index: 2;
    font-family: inherit;
}

.trip-item:hover .trip-delete-btn,
.trip-delete-btn:focus-visible {
    opacity: 1;
    pointer-events: auto;
}

.trip-delete-btn:hover {
    color: #7f1d1d;
    background: rgba(127, 29, 29, 0.08);
}

.trip-chevron {
    color: var(--inkSoft);
    font-size: 18px;
    flex-shrink: 0;
    margin-left: auto;
    line-height: 1;
}

.trip-submenu {
    position: fixed;
    width: 210px;
    background: var(--surface);
    border-radius: 12px;
    box-shadow: 0 8px 24px rgba(14, 37, 64, 0.10);
    padding: 6px;
    z-index: 960;
    display: flex;
    flex-direction: column;
    gap: 2px;
}

.trip-submenu[hidden] {
    display: none;
}

.trip-submenu-item {
    display: block;
    padding: 9px 12px;
    color: var(--ink);
    text-decoration: none;
    border-radius: 8px;
    font-size: 13px;
    font-weight: 500;
    transition: background-color 0.15s ease;
}

.trip-submenu-item:hover {
    background: var(--bg2);
}

.trip-submenu-item--disabled {
    color: var(--inkSoft);
    cursor: not-allowed;
    pointer-events: none;
}

.trips-dropdown-empty {
    padding: 16px 12px;
    color: var(--inkSoft);
    font-size: 14px;
    text-align: center;
}

.trips-blur-backdrop {
    position: fixed;
    left: 0;
    right: 0;
    bottom: 0;
    top: 0;
    backdrop-filter: blur(4px);
    -webkit-backdrop-filter: blur(4px);
    background: rgba(14, 37, 64, 0.08);
    z-index: 800;
    pointer-events: none;
}

.trips-blur-backdrop[hidden] {
    display: none;
}

/* ── App toasts ────────────────────────────────────────────── */
.app-toast-container {
    position: fixed;
    top: 1rem;
    right: 1rem;
    z-index: 1100;
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
    pointer-events: none;
}

.app-toast {
    pointer-events: auto;
    min-width: 220px;
    max-width: 360px;
    padding: 0.7rem 1rem;
    border-radius: 8px;
    font-size: 0.88rem;
    font-weight: 500;
    box-shadow: 0 6px 18px rgba(14, 37, 64, 0.08);
    border: 1px solid transparent;
    transform: translateX(0);
    opacity: 1;
    transition: opacity 0.35s, transform 0.35s;
}

.app-toast--success {
    background: #E8F1EA;
    color: #16a34a;
    border-color: #C9DDD0;
}

.app-toast--info {
    background: #E6EDF7;
    color: #1A3A6B;
    border-color: #C8D5EB;
}

.app-toast--error {
    background: #FBECEC;
    color: #7A1E1E;
    border-color: #F0CFCF;
}

.app-toast--leaving {
    opacity: 0;
    transform: translateX(20px);
}

/* ── Email confirmation banner ─────────────────────────────── */
.email-confirm-banner {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 12px;
    padding: 10px 16px;
    background: #E6EDF7;
    color: #1A3A6B;
    border-bottom: 1px solid #C8D5EB;
    font-size: 14px;
    font-weight: 500;
    text-align: center;
    flex-wrap: wrap;
}

.email-confirm-text {
    line-height: 1.4;
}

.email-confirm-form {
    margin: 0;
    display: inline-flex;
}

.email-confirm-resend {
    background: transparent;
    border: none;
    padding: 0;
    color: #1A3A6B;
    font-family: inherit;
    font-size: 14px;
    font-weight: 600;
    text-decoration: underline;
    cursor: pointer;
}

.email-confirm-resend:hover {
    text-decoration: none;
}

.ai-disclaimer {
    margin-top: 1rem;
    font-size: 0.75rem;
    color: var(--inkMuted);
    line-height: 1.5;
}

