/* PODCO frontend v11.53 — profile, rewards, trust, publish and speed polish */
:root{--p53-blue:#0b4f83;--p53-ink:#17324e;--p53-muted:#687e8d;--p53-line:#dce6ea;--p53-soft:#f5f9fa;--p53-success:#237650}

/* Keep important controls usable on iPhone while requests continue in the background. */
button,a,input,select,textarea{touch-action:manipulation}
button:not([hidden]),a:not([hidden]){min-height:44px}
[hidden]{pointer-events:none!important}
.mobile-bottom-nav{pointer-events:auto!important;z-index:2147482500!important}
.mobile-bottom-nav a{pointer-events:auto!important}

/* Compact account identity: photo first, name secondary. */
.p53-account-identity{display:flex;align-items:center;gap:15px;margin:4px 0 12px;padding:4px 0;min-width:0}
.p53-account-avatar,.p53-host-avatar{width:76px;height:76px;flex:0 0 76px;border-radius:50%;overflow:hidden;display:grid;place-items:center;background:#e9f3f7;color:var(--p53-blue);font:800 28px/1 system-ui;border:1px solid #cddfe6}
.p53-account-avatar img,.p53-host-avatar img{width:100%;height:100%;display:block;object-fit:cover;object-position:center}
.p53-account-copy{min-width:0}
.p53-account-copy .podco-page-eyebrow{margin:0 0 4px!important}
.p53-account-copy h1{font-family:Inter,ui-sans-serif,system-ui,-apple-system,sans-serif!important;font-size:clamp(26px,5vw,36px)!important;line-height:1.08!important;margin:0 0 4px!important;max-width:100%!important;white-space:normal;overflow-wrap:anywhere}
.p53-account-copy .podco-status-note{margin:0!important;color:var(--p53-muted)!important}
.podco-account-shell>.podco-lead{margin-top:8px!important}

/* Rewards: compact summary on Account/Profile, detailed page stays scannable. */
.p53-rewards-summary{display:grid;gap:9px;border:1px solid var(--p53-line);border-radius:17px;background:#fff;padding:14px 15px;margin:10px 0 8px;color:var(--p53-ink)}
.p53-rewards-top{display:flex;align-items:center;gap:10px;min-width:0}
.p53-rewards-icon{width:40px;height:40px;flex:0 0 40px;border-radius:13px;display:grid;place-items:center;background:#eef6f8;font-size:22px}
.p53-rewards-copy{min-width:0;flex:1}
.p53-rewards-copy strong{display:block;font-size:16px;line-height:1.2;color:var(--p53-ink)}
.p53-rewards-copy small{display:block;margin-top:3px;color:var(--p53-muted);font-size:12px}
.p53-rewards-progress{height:7px;border-radius:999px;overflow:hidden;background:#e6eef1}
.p53-rewards-progress>span{height:100%;display:block;border-radius:inherit;background:var(--p53-blue)}
.p53-rewards-footer{display:flex;justify-content:space-between;gap:10px;align-items:center;flex-wrap:wrap;font-size:12px;color:var(--p53-muted)}
.p53-rewards-footer a{min-height:unset;color:var(--p53-blue);font-weight:800;text-decoration:none;padding:3px 0}
[data-podco-account-rewards] .podco-member-level,[data-podco-profile-rewards] .podco-member-level,[data-podco-profile-rewards] .podco-profile-level-preview{display:none!important}
[data-podco-account-rewards],[data-podco-profile-rewards]{margin:8px 0 12px!important}

/* Dedicated rewards page: remove oversized hero treatment. */
.p53-rewards-page{display:grid;gap:14px}
.p53-rewards-page .p53-rewards-summary{margin:0}
.p53-level-grid{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:9px}
.p53-level-card{border:1px solid var(--p53-line);background:#fff;border-radius:15px;padding:12px;display:grid;gap:5px;min-height:92px}
.p53-level-card.current{border-color:#8bb8ce;box-shadow:0 0 0 1px #8bb8ce inset;background:#f5fafc}
.p53-level-card .top{display:flex;justify-content:space-between;gap:8px;align-items:center}
.p53-level-card .emoji{font-size:20px}
.p53-level-card .state{font-size:9px;font-weight:850;text-transform:uppercase;letter-spacing:.05em;color:var(--p53-muted)}
.p53-level-card strong{font-size:13px;line-height:1.25;color:var(--p53-ink)}
.p53-level-card small{font-size:11px;color:var(--p53-muted)}
.p53-level-card b{font-size:11px;color:#0b6d75}

/* Profile image editor and true circular presentation. */
.p49-avatar-wrap{align-items:center!important}
.p49-avatar{width:112px!important;height:112px!important;aspect-ratio:1/1!important;border-radius:50%!important;overflow:hidden!important;object-fit:cover!important;object-position:center!important;display:grid!important;place-items:center!important}
.p49-avatar img{width:100%!important;height:100%!important;object-fit:cover!important}
.p53-crop-backdrop{position:fixed;inset:0;z-index:2147483600;background:rgba(10,29,43,.72);display:grid;place-items:center;padding:18px}
.p53-crop-dialog{width:min(520px,100%);max-height:calc(100vh - 36px);overflow:auto;background:#fff;border-radius:22px;padding:20px;box-sizing:border-box}
.p53-crop-dialog h2{margin:0 0 6px;color:var(--p53-ink);font-size:24px}
.p53-crop-dialog p{margin:0 0 14px;color:var(--p53-muted)}
.p53-crop-stage{width:min(320px,100%);aspect-ratio:1/1;margin:0 auto;border-radius:50%;overflow:hidden;background:#eaf1f4;position:relative;box-shadow:0 0 0 1px var(--p53-line) inset}
.p53-crop-stage canvas{width:100%;height:100%;display:block}
.p53-crop-controls{display:grid;gap:11px;margin:17px 0}
.p53-crop-controls label{display:grid;gap:6px;font-weight:750;color:var(--p53-ink);font-size:13px}
.p53-crop-controls input[type=range]{width:100%}
.p53-crop-actions{display:flex;justify-content:flex-end;gap:9px;flex-wrap:wrap}
.p53-crop-actions button{border-radius:12px;padding:10px 15px;border:1px solid var(--p53-line);background:#fff;font-weight:800;color:var(--p53-ink)}
.p53-crop-actions .primary{background:var(--p53-blue);color:#fff;border-color:var(--p53-blue)}

/* Host account/profile. */
.p53-host-identity{display:flex;align-items:center;gap:14px;margin-bottom:15px}
.p53-host-identity .p53-host-avatar{width:68px;height:68px;flex-basis:68px;font-size:24px}
.p53-host-identity h2{margin:0 0 3px!important;font-size:24px!important}
.p53-host-identity p{margin:0!important;color:var(--p53-muted)}
.p53-host-profile-form{display:grid;gap:13px;margin-top:16px}
.p53-host-profile-form label{display:grid;gap:7px;font-weight:750;color:var(--p53-ink)}
.p53-host-profile-form textarea,.p53-host-profile-form input{box-sizing:border-box;width:100%;min-height:48px;border:1px solid #cadbe3;border-radius:12px;padding:12px 13px;background:#fff;font:inherit;color:var(--p53-ink)}
.p53-host-profile-form textarea{min-height:126px;resize:vertical}
.p53-char-count{text-align:right;color:var(--p53-muted);font-size:11px}

/* Trust reputation and host favourites. */
.p53-badges{display:flex;gap:7px;align-items:center;flex-wrap:wrap;margin:8px 0}
.p53-badge{display:inline-flex;align-items:center;gap:5px;min-height:28px!important;border-radius:999px;padding:5px 9px;background:#edf5f8;color:#31566d;font-size:11px;font-weight:850;text-decoration:none}
.p53-badge.trusted{background:#eaf5ef;color:#246347}
.p53-badge.guest-favourite{background:#f5f1e9;color:#725c2d}
.p53-favourite-host{display:inline-flex;align-items:center;justify-content:center;gap:6px;border:1px solid #cadce4;background:#fff;color:var(--p53-blue);border-radius:12px;padding:9px 12px;font-weight:800}
.p53-favourite-host.saved{background:#eef7fa}
.p53-host-favourites{margin-top:18px}
.p53-host-favourite-row{display:flex;align-items:center;gap:12px;padding:12px 0;border-top:1px solid var(--p53-line)}
.p53-host-favourite-row:first-child{border-top:0}
.p53-host-favourite-row .p53-host-avatar{width:48px;height:48px;flex-basis:48px;font-size:18px}
.p53-host-favourite-row>div{min-width:0;flex:1}
.p53-host-favourite-row strong,.p53-host-favourite-row small{display:block}
.p53-host-favourite-row small{color:var(--p53-muted);margin-top:3px}

/* Publishing: one visible progress state and recoverable errors. */
.p53-publish-status{margin-top:12px;padding:11px 12px;border-radius:12px;background:#f2f7f9;color:#446274;font-size:13px;line-height:1.4}
.p53-publish-status.error{background:#fff2f2;color:#97363b}
.p45-publish-button[disabled]{opacity:.72;cursor:wait}

/* Search map should never present as an empty black slab. */
#podco-modern-map-canvas,.podco-modern-map-canvas{background:linear-gradient(180deg,#eaf3f6,#f7fafb)!important;color:var(--p53-ink)}
.podco-modern-map-shell.map-failed #podco-modern-map-canvas{min-height:220px!important;height:auto!important}
.podco-map-fallback{min-height:220px;display:grid;place-items:center;align-content:center;gap:5px;padding:22px;text-align:center;background:#f5f9fa;color:var(--p53-ink)}
.podco-map-fallback span{color:var(--p53-muted);font-size:13px}

/* More compact account tiles on mobile. */
@media(max-width:820px){
  .podco-account-shell,.podco-detail-shell{padding-top:20px!important}
  .p53-account-avatar{width:66px;height:66px;flex-basis:66px;font-size:24px}
  .podco-account-grid{gap:10px!important;margin-top:14px!important}
  .podco-account-tile{min-height:0!important;padding:15px!important;border-radius:17px!important}
  .podco-account-tile strong{font-size:18px!important;margin-bottom:4px!important}
  .podco-account-tile span:not(.podco-setting-icon):not(.podco-setting-arrow){font-size:13px!important}
  .p53-level-grid{grid-template-columns:1fr 1fr}
  .p49-profile-card{padding:16px!important}
}
@media(max-width:430px){
  .p53-level-grid{grid-template-columns:1fr}
  .p53-rewards-footer{display:grid}
  .p53-host-favourite-row{align-items:flex-start}
}
.p53-search-image-wrap{position:relative}
.p53-search-image-wrap>img{display:block;width:100%}
.p53-search-badge{position:absolute;left:10px;top:10px;display:inline-flex;align-items:center;min-height:28px;border-radius:999px;background:rgba(255,255,255,.94);padding:5px 9px;color:#5d4b26;font-size:11px;font-weight:850;box-shadow:0 1px 5px rgba(20,45,61,.12)}
