.account-page, .dashboard-page { min-height: 100vh; background: var(--surface); }
.account-header { position: fixed; z-index: 20; inset: 0 0 auto; height: 78px; background: rgba(255,255,255,.94); border-bottom: 1px solid var(--line); backdrop-filter: blur(14px); }
.account-header-inner { height: 100%; display: flex; align-items: center; justify-content: space-between; }
.back-link { display: flex; align-items: center; gap: 8px; color: var(--teal-700); font-weight: 800; font-size: 14px; }
.account-main { min-height: 100vh; display: grid; grid-template-columns: minmax(390px, .9fr) minmax(600px, 1.1fr); padding-top: 78px; }
.account-visual { position: sticky; top: 78px; height: calc(100vh - 78px); display: flex; align-items: end; padding: 64px; color: var(--white); background: var(--navy-950) url("../assets/pontos-turisticos/convento-da-penha.webp") center / cover no-repeat; }
.account-visual-overlay { position: absolute; inset: 0; background: linear-gradient(180deg, rgba(2,31,45,.18), rgba(2,31,45,.94)); }
.account-visual-copy { position: relative; z-index: 1; max-width: 520px; }
.account-visual h1 { margin-bottom: 22px; font-size: clamp(43px, 4.4vw, 66px); letter-spacing: -.055em; }
.account-visual h1 em { color: #8be1d8; }
.account-visual-copy > p:not(.eyebrow) { color: rgba(255,255,255,.76); font-size: 17px; }
.account-benefits { display: flex; flex-wrap: wrap; gap: 14px 20px; margin-top: 28px; font-size: 13px; }
.account-benefits span { display: flex; align-items: center; gap: 8px; }
.account-benefits i { width: 22px; height: 22px; display: grid; place-items: center; color: var(--navy-950); background: #9ee5dc; border-radius: 50%; font-style: normal; font-weight: 900; }
.auth-panel { display: flex; justify-content: center; padding: 60px 42px 80px; background: var(--white); }
.auth-shell { width: min(100%, 660px); }
.auth-intro h2 { margin-bottom: 8px; color: var(--navy-950); font-size: clamp(34px, 4vw, 46px); letter-spacing: -.04em; }
.auth-intro > p:last-child { color: var(--muted); }
.auth-tabs { display: grid; grid-template-columns: 1fr 1fr; margin: 32px 0 24px; padding: 5px; background: var(--surface); border: 1px solid var(--line); border-radius: 14px; }
.auth-tabs button { min-height: 46px; color: var(--muted); background: transparent; border: 0; border-radius: 10px; cursor: pointer; font-weight: 800; }
.auth-tabs button.active { color: var(--navy-900); background: var(--white); box-shadow: var(--shadow-sm); }
.form-alert { margin-bottom: 18px; padding: 12px 14px; color: #8a2d1d; background: #fff1ed; border: 1px solid #ffd1c7; border-radius: 10px; font-size: 13px; }
.form-alert.success { color: #075f55; background: #e9faf7; border-color: #b7e9df; }
.auth-form { display: grid; gap: 18px; }
.register-form { grid-template-columns: 1fr 1fr; }
.auth-form label:not(.check-line) { display: grid; gap: 7px; }
.auth-form label > span:first-child { color: var(--ink); font-size: 12px; font-weight: 800; }
.auth-form input:not([type="checkbox"]), .auth-form select { width: 100%; min-height: 50px; padding: 0 14px; color: var(--ink); background: var(--surface); border: 1px solid var(--line); border-radius: 11px; outline: 0; }
.auth-form input:focus { background: var(--white); border-color: var(--teal-500); box-shadow: 0 0 0 3px rgba(24,184,184,.12); }
.auth-form small { color: var(--muted); font-size: 10px; }
.password-field { position: relative; display: block; }
.password-field input { padding-right: 76px !important; }
.password-toggle { position: absolute; right: 7px; top: 7px; height: 36px; padding: 0 10px; color: var(--teal-700); background: transparent; border: 0; cursor: pointer; font-size: 11px; font-weight: 800; }
.auth-options { display: flex; align-items: center; justify-content: space-between; gap: 20px; }
.check-line { display: flex; align-items: flex-start; gap: 9px; color: var(--muted); font-size: 12px; cursor: pointer; }
.check-line input { width: 16px; height: 16px; margin-top: 2px; accent-color: var(--teal-700); }
.muted-link { color: #97a7ac; font-size: 11px; }
.submit-button { width: 100%; min-height: 54px; }
.button-loader, .large-loader { width: 20px; height: 20px; border: 2px solid rgba(255,255,255,.4); border-top-color: var(--white); border-radius: 50%; animation: spin .75s linear infinite; }
.large-loader { width: 34px; height: 34px; border-color: rgba(8,125,131,.18); border-top-color: var(--teal-700); }
@keyframes spin { to { transform: rotate(360deg); } }
.full-field { grid-column: 1 / -1; }
.photo-upload { display: flex; align-items: center; gap: 16px; padding: 16px; background: var(--aqua-50); border: 1px dashed #9edbd6; border-radius: 14px; }
.photo-preview { width: 72px; height: 72px; display: grid; place-items: center; flex: none; overflow: hidden; padding: 0; color: var(--teal-700); background: var(--white); border: 2px solid var(--teal-100); border-radius: 50%; cursor: pointer; font-size: 28px; }
.photo-preview img { width: 100%; height: 100%; object-fit: cover; }
.photo-upload-copy { display: grid; justify-items: start; }
.upload-button { display: inline-flex; margin-bottom: 4px; color: var(--teal-700); cursor: pointer; font-size: 13px; font-weight: 800; }
.photo-adjust-button { margin: 2px 0 5px; padding: 0; color: var(--navy-900); background: none; border: 0; cursor: pointer; font-size: 11px; font-weight: 800; text-decoration: underline; }
.privacy-check button { padding: 0; color: var(--teal-700); background: none; border: 0; cursor: pointer; text-decoration: underline; }
.security-note { display: flex; align-items: flex-start; gap: 8px; margin: 24px 0 0; padding-top: 18px; color: var(--muted); border-top: 1px solid var(--line); font-size: 11px; }
.privacy-modal { width: min(620px, calc(100% - 30px)); padding: 42px; border-radius: var(--radius-md); box-shadow: var(--shadow-lg); }
.privacy-modal h2 { font-size: 32px; }
.privacy-modal p:not(.eyebrow) { color: var(--muted); }

/* Dashboard */
.dashboard-loading { min-height: 100vh; display: grid; place-items: center; align-content: center; gap: 15px; color: var(--muted); }
.dashboard-app { min-height: 100vh; grid-template-columns: 260px 1fr; }
.dashboard-app:not([hidden]) { display: grid; }
.dashboard-sidebar { position: fixed; z-index: 40; left: 0; top: 0; bottom: 0; width: 260px; display: flex; flex-direction: column; padding: 26px 20px; color: var(--white); background: linear-gradient(180deg, #032f40, #021f2d); }
.dashboard-sidebar .brand { margin-bottom: 45px; }
.dashboard-sidebar nav { display: grid; gap: 5px; }
.dashboard-sidebar nav button { display: flex; align-items: center; gap: 13px; min-height: 47px; padding: 0 14px; color: rgba(255,255,255,.65); background: transparent; border: 0; border-radius: 11px; cursor: pointer; text-align: left; font-weight: 700; }
.dashboard-sidebar nav button span { width: 24px; font-size: 18px; text-align: center; }
.dashboard-sidebar nav button:hover, .dashboard-sidebar nav button.active { color: var(--white); background: linear-gradient(90deg, var(--teal-700), var(--teal-600)); }
.sidebar-help { margin-top: auto; padding: 18px; background: rgba(255,255,255,.06); border: 1px solid rgba(255,255,255,.1); border-radius: 16px; }
.sidebar-help > span { width: 36px; height: 36px; display: grid; place-items: center; color: var(--navy-950); background: #9ee5dc; border-radius: 50%; }
.sidebar-help h3 { margin: 13px 0 5px; font-size: 14px; }
.sidebar-help p { color: rgba(255,255,255,.58); font-size: 11px; }
.sidebar-help a { color: #9ee5dc; font-size: 12px; font-weight: 800; }
.logout-button { display: flex; align-items: center; gap: 10px; margin-top: 16px; padding: 12px; color: rgba(255,255,255,.66); background: transparent; border: 0; cursor: pointer; text-align: left; }
.dashboard-main { grid-column: 2; min-width: 0; }
.dashboard-topbar { position: sticky; z-index: 30; top: 0; min-height: 88px; display: flex; align-items: center; gap: 24px; padding: 14px clamp(25px, 4vw, 58px); background: rgba(255,255,255,.96); border-bottom: 1px solid var(--line); backdrop-filter: blur(14px); }
.dashboard-topbar p, .dashboard-topbar h1 { margin: 0; }
.dashboard-topbar p { color: var(--muted); font-size: 10px; text-transform: uppercase; letter-spacing: .12em; }
.dashboard-topbar h1 { color: var(--navy-950); font-size: 22px; }
.explore-link { margin-left: auto; color: var(--teal-700); font-size: 12px; font-weight: 800; }
.profile-menu { display: flex; align-items: center; gap: 10px; padding-left: 20px; border-left: 1px solid var(--line); }
.profile-menu img { width: 44px; height: 44px; display: block; object-fit: cover; background: var(--teal-100); border-radius: 50%; }
.profile-menu > span { display: grid; line-height: 1.2; }
.profile-menu strong { font-size: 12px; }
.profile-menu small { color: var(--muted); font-size: 10px; }
.profile-photo-button { position: relative; padding: 0; background: transparent; border: 0; border-radius: 50%; cursor: pointer; }
.profile-photo-button > span { position: absolute; right: -3px; bottom: -2px; width: 19px; height: 19px; display: grid; place-items: center; color: var(--white); background: var(--teal-700); border: 2px solid var(--white); border-radius: 50%; font-size: 9px; line-height: 1; }
.profile-photo-button:disabled { cursor: wait; opacity: .6; }
.dashboard-menu { display: none; width: 42px; height: 42px; background: var(--surface); border: 1px solid var(--line); border-radius: 10px; }
.dashboard-content { padding: 45px clamp(25px, 4vw, 58px) 80px; }
.dashboard-welcome { display: flex; align-items: end; justify-content: space-between; gap: 30px; margin-bottom: 30px; }
.dashboard-welcome h2 { margin-bottom: 6px; color: var(--navy-950); font-size: 38px; letter-spacing: -.04em; }
.dashboard-welcome > div:first-child > p:last-child { margin: 0; color: var(--muted); }
.dashboard-date { display: grid; padding: 12px 18px; background: var(--white); border: 1px solid var(--line); border-radius: 12px; box-shadow: var(--shadow-sm); }
.dashboard-date span { color: var(--muted); font-size: 10px; text-transform: uppercase; }
.dashboard-date strong { font-size: 13px; }
.stats-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 18px; margin-bottom: 42px; }
.stats-grid article { display: flex; align-items: center; gap: 16px; padding: 22px; background: var(--white); border: 1px solid var(--line); border-radius: 16px; box-shadow: var(--shadow-sm); }
.stat-icon { width: 48px; height: 48px; display: grid; place-items: center; flex: none; border-radius: 14px; font-size: 22px; }
.stat-icon.teal { color: var(--teal-700); background: var(--teal-100); }
.stat-icon.blue { color: #246bc4; background: #eaf3ff; }
.stat-icon.orange { color: var(--orange-dark); background: #fff0df; }
.stats-grid article > div { display: grid; }
.stats-grid small { color: var(--muted); font-size: 10px; text-transform: uppercase; }
.stats-grid strong { color: var(--navy-950); font-size: 29px; line-height: 1.2; }
.stats-grid article span:last-child { color: #98a7ac; font-size: 10px; }
.dashboard-section-head { display: flex; align-items: end; justify-content: space-between; gap: 20px; margin-bottom: 20px; }
.dashboard-section-head h2 { margin-bottom: 5px; font-size: 23px; }
.dashboard-section-head p { margin: 0; color: var(--muted); font-size: 13px; }
.dashboard-tabs { display: flex; padding: 4px; background: #eaf1f1; border-radius: 10px; }
.dashboard-tabs button { min-height: 36px; padding: 0 13px; color: var(--muted); background: transparent; border: 0; border-radius: 8px; cursor: pointer; font-size: 11px; font-weight: 700; }
.dashboard-tabs button.active { color: var(--navy-900); background: var(--white); box-shadow: 0 4px 12px rgba(2,47,64,.09); }
.user-trip-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 20px; }
.user-trip-card { overflow: hidden; background: var(--white); border: 1px solid var(--line); border-radius: 18px; box-shadow: var(--shadow-sm); }
.user-trip-photo { position: relative; min-height: 180px; padding: 15px; }
.trip-status { display: inline-flex; align-items: center; gap: 6px; padding: 6px 10px; border-radius: 999px; font-size: 9px; font-weight: 800; text-transform: uppercase; letter-spacing: .04em; }
.trip-status.pending { color: #8a5b00; background: #fff0c7; }
.trip-status.approved { color: #076154; background: #dff8f1; }
.trip-status.completed { color: #345b93; background: #e9f2ff; }
.trip-status.cancelled { color: #8a2d1d; background: #ffe8e3; }
.user-trip-body { padding: 20px; }
.user-trip-body h3 { margin-bottom: 6px; font-size: 20px; }
.user-trip-destination { margin-bottom: 16px; color: var(--muted); font-size: 12px; }
.trip-facts { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; padding: 14px 0; border-block: 1px solid var(--line); }
.trip-facts span { display: grid; color: var(--muted); font-size: 9px; text-transform: uppercase; }
.trip-facts strong { color: var(--ink); font-size: 12px; text-transform: none; }
.trip-card-footer { display: flex; align-items: center; justify-content: space-between; gap: 15px; margin-top: 15px; }
.trip-card-footer span { display: grid; color: var(--muted); font-size: 9px; }
.trip-card-footer strong { color: var(--navy-900); font-size: 17px; }
.trip-card-footer a { color: var(--teal-700); font-size: 11px; font-weight: 800; }
.dashboard-empty { padding: 60px 30px; text-align: center; background: var(--white); border: 1px dashed var(--line); border-radius: 18px; }
.dashboard-empty > span { width: 58px; height: 58px; display: grid; place-items: center; margin: 0 auto 15px; color: var(--teal-700); background: var(--aqua-50); border-radius: 50%; font-size: 25px; }
.dashboard-empty h3 { margin-bottom: 6px; }
.dashboard-empty p { color: var(--muted); }

/* Editor de foto compartilhado entre cadastro e área do viajante */
.photo-editor-modal { width: min(600px, calc(100% - 26px)); max-height: calc(100dvh - 26px); overflow: auto; border-radius: 22px; box-shadow: var(--shadow-lg); }
.photo-editor-shell { padding: clamp(22px, 4vw, 38px); }
.photo-editor-heading { display: flex; align-items: flex-start; justify-content: space-between; gap: 22px; }
.photo-editor-heading h2 { margin: 2px 0 7px; color: var(--navy-950); font-size: clamp(27px, 5vw, 37px); letter-spacing: -.04em; }
.photo-editor-heading > div > p:last-child { margin: 0; color: var(--muted); font-size: 13px; }
.photo-editor-close { width: 38px; height: 38px; display: grid; place-items: center; flex: none; color: var(--muted); background: var(--surface); border: 1px solid var(--line); border-radius: 50%; cursor: pointer; font-size: 23px; line-height: 1; }
.photo-editor-stage { position: relative; width: min(320px, 78vw); aspect-ratio: 1; margin: 26px auto 22px; overflow: hidden; background: #dce8e8; border: 5px solid var(--white); border-radius: 50%; box-shadow: 0 0 0 1px var(--line), 0 16px 38px rgba(2,47,64,.18); touch-action: none; }
.photo-editor-stage canvas { width: 100%; height: 100%; display: block; cursor: grab; }
.photo-editor-stage canvas.dragging { cursor: grabbing; }
.photo-editor-guide { position: absolute; pointer-events: none; inset: 11%; border: 1px dashed rgba(255,255,255,.82); border-radius: 50%; box-shadow: 0 0 0 999px rgba(2,31,45,.08); }
.photo-editor-controls { display: grid; gap: 14px; padding: 16px; background: var(--surface); border: 1px solid var(--line); border-radius: 14px; }
.photo-editor-controls label { display: grid; grid-template-columns: auto 1fr auto; align-items: center; gap: 10px; color: var(--muted); font-size: 10px; font-weight: 700; }
.photo-editor-controls input { width: 100%; accent-color: var(--teal-700); cursor: pointer; }
.photo-editor-tools { display: flex; justify-content: center; gap: 8px; }
.photo-editor-tools button { min-height: 36px; padding: 0 12px; color: var(--teal-700); background: var(--white); border: 1px solid var(--line); border-radius: 9px; cursor: pointer; font-size: 12px; font-weight: 800; }
.photo-editor-actions { display: grid; grid-template-columns: 1fr 1.35fr; gap: 11px; margin-top: 20px; }
.photo-editor-actions .button { width: 100%; min-height: 50px; }
.photo-editor-cancel { color: var(--navy-900); background: var(--white); border-color: var(--line); }

@media (max-width: 1050px) {
  .account-main { grid-template-columns: .8fr 1.2fr; }
  .account-visual { padding: 40px; }
  .auth-panel { padding-inline: 30px; }
  .dashboard-sidebar { width: 220px; }
  .dashboard-app { grid-template-columns: 220px 1fr; }
  .profile-menu > span { display: none; }
  .stats-grid { grid-template-columns: 1fr; }
}

@media (max-width: 820px) {
  .account-header { position: static; }
  .account-main { display: block; padding-top: 0; }
  .account-visual { position: relative; top: 0; height: auto; min-height: 420px; padding: 70px 30px 45px; }
  .auth-panel { padding: 50px 24px 70px; }
  .dashboard-app { display: block !important; }
  .dashboard-sidebar { transform: translateX(-105%); width: 260px; transition: transform .25s ease; box-shadow: var(--shadow-lg); }
  .dashboard-sidebar.open { transform: translateX(0); }
  .dashboard-main { min-width: 0; }
  .dashboard-menu { display: block; }
  .explore-link { display: none; }
  .profile-menu { margin-left: auto; }
  .user-trip-grid { grid-template-columns: 1fr; }
}

@media (max-width: 560px) {
  .account-header { height: 68px; }
  .account-header .brand img { width: 44px; height: 44px; }
  .back-link { font-size: 0; }
  .back-link span { font-size: 20px; }
  .account-visual { min-height: 360px; }
  .account-visual h1 { font-size: 42px; }
  .register-form { grid-template-columns: 1fr; }
  .full-field { grid-column: auto; }
  .auth-options { align-items: flex-start; flex-direction: column; gap: 8px; }
  .privacy-modal { padding: 38px 22px 25px; }
  .dashboard-topbar { padding-inline: 16px; }
  .dashboard-topbar > div:nth-of-type(1) p { display: none; }
  .dashboard-topbar h1 { font-size: 17px; }
  .profile-menu { padding-left: 10px; }
  .dashboard-content { padding: 28px 16px 60px; }
  .dashboard-welcome { display: block; }
  .dashboard-date { width: fit-content; margin-top: 18px; }
  .dashboard-section-head { align-items: flex-start; flex-direction: column; }
  .dashboard-tabs { width: 100%; overflow-x: auto; }
  .trip-facts { grid-template-columns: 1fr 1fr; }
  .photo-editor-shell { padding: 22px 18px; }
  .photo-editor-stage { margin-block: 20px 18px; }
  .photo-editor-tools button span { display: none; }
  .photo-editor-actions { grid-template-columns: 1fr; }
}
