/* ============================================================ PLANET PAGE */

.planet-hero {
    padding-top: clamp(96px, 12vw, 160px);
    padding-bottom: clamp(48px, 6vw, 72px);
}
.planet-hero .lead { max-width: 620px; margin-top: 22px; }

/* --------------------------------------------------- dark stage band */
.planet-stage {
    background: #04050a;
    color: #f5f5f7;
    padding: clamp(40px, 6vw, 72px) 0 clamp(48px, 6vw, 72px);
    overflow: hidden;
}

.planet-viewport {
    position: relative;
    width: 100%;
    height: clamp(520px, 88vh, 900px);
}
.planet-canvas-wrap {
    width: 100%;
    max-width: none;
    height: 100%;
    margin: 0;
    padding: 0;
    position: relative;
    overflow: hidden;
}
.planet-canvas-wrap canvas {
    display: block;
    width: 100%;
    height: 100%;
}
.planet-canvas-wrap canvas[data-planet] {
    cursor: grab;
    touch-action: pan-y;
}
.planet-canvas-wrap canvas[data-planet].is-grabbing { cursor: grabbing; }

/* People and location pins live in a DOM layer above the animated canvases.
   Text, emoji, borders and portraits are therefore rerasterized by the
   browser at the current Retina/page-zoom scale instead of enlarging pixels
   from the globe canvas. */
.planet-marker-layer {
    position: absolute;
    inset: 0;
    z-index: 3;
    overflow: hidden;
    pointer-events: none;
}
.planet-map-marker {
    position: absolute;
    left: 0;
    top: 0;
    width: 0;
    height: 0;
    display: block;
    will-change: transform, opacity;
}
.planet-map-marker[hidden] { display: none; }
.planet-marker-bubble {
    position: absolute;
    left: 0;
    bottom: 13px;
    width: 27px;
    height: 27px;
    transform: translateX(-50%);
    display: grid;
    place-items: center;
    box-sizing: border-box;
    color: #111;
    filter: drop-shadow(0 2px 3px rgba(0, 0, 0, 0.28));
}
.planet-marker-bubble::after {
    content: '';
    position: absolute;
    z-index: -1;
    left: 50%;
    top: calc(100% - 1px);
    width: 0;
    height: 0;
    transform: translateX(-50%);
    border-left: 4.5px solid transparent;
    border-right: 4.5px solid transparent;
    border-top: 11px solid var(--marker-pointer);
}
.planet-marker-content {
    display: grid;
    place-items: center;
    width: 100%;
    height: 100%;
    box-sizing: border-box;
}
.planet-marker-bubble.is-symbol {
    border: 1.2px solid var(--marker-border);
    border-radius: 50%;
    background: var(--marker-fill);
    font: 15px/1 -apple-system, BlinkMacSystemFont, "Apple Color Emoji", "Segoe UI Emoji", sans-serif;
}
.planet-marker-bubble.is-avatar {
    border: 1.4px solid rgba(255, 255, 255, 0.94);
    border-radius: 50%;
    background: var(--marker-border);
    padding: 1px;
}
.planet-marker-bubble.is-avatar .planet-marker-content {
    border-radius: 50%;
    background-repeat: no-repeat;
}
.planet-marker-bubble.is-large {
    width: 36.45px;
    height: 36.45px;
}
.planet-marker-bubble.is-symbol.is-large { font-size: 20px; }
.planet-marker-bubble.is-text {
    width: auto;
    height: 21px;
    min-width: max-content;
    padding: 0 7.5px;
    border: 1.2px solid var(--marker-border);
    border-radius: 999px;
    background: var(--marker-fill);
    color: rgba(32, 25, 8, 0.96);
    font: 700 11.5px/1 Inter, -apple-system, BlinkMacSystemFont, sans-serif;
    letter-spacing: -0.01em;
    white-space: nowrap;
}
.planet-marker-badge {
    position: absolute;
    top: -5px;
    right: -5px;
    font: 11px/1 -apple-system, BlinkMacSystemFont, "Apple Color Emoji", "Segoe UI Emoji", sans-serif;
}
.planet-marker-badge:empty { display: none; }
.planet-marker-anchor {
    position: absolute;
    left: -2.2px;
    top: -2.2px;
    width: 4.4px;
    height: 4.4px;
    border-radius: 50%;
    background: var(--marker-anchor);
    box-shadow: 0 0 5px color-mix(in srgb, var(--marker-anchor) 72%, transparent);
}

.planet-under {
    margin-top: clamp(20px, 3vw, 32px);
    text-align: center;
}
.planet-caption {
    font-size: 15px;
    line-height: 1.6;
    color: rgba(245, 245, 247, 0.66);
    max-width: 520px;
    margin: 0 auto;
}
.planet-caption strong { color: #f5d98f; font-weight: 600; }


/* --------------------------------------------------- key & fine print */
.planet-key {
    margin-top: 16px;
    display: flex;
    justify-content: center;
    gap: 18px;
    flex-wrap: wrap;
}
.planet-key-item {
    display: inline-flex;
    align-items: center;
    gap: 7px;
    font-size: 12.5px;
    letter-spacing: 0.01em;
    color: rgba(245, 245, 247, 0.55);
}
.planet-key-dot { width: 8px; height: 8px; border-radius: 50%; }
.planet-key-customer { background: #f5d98f; box-shadow: 0 0 8px rgba(245, 217, 143, 0.8); }
.planet-key-visitor { background: #5aa9ff; box-shadow: 0 0 6px rgba(90, 169, 255, 0.6); }
.planet-key-download { background: #c4b5fd; box-shadow: 0 0 8px rgba(196, 181, 253, 0.85); }
.planet-key-live { background: #34d399; box-shadow: 0 0 10px rgba(52, 211, 153, 0.95); animation: planetPulse 1.6s infinite; }
.planet-key-studio { background: #fb923c; box-shadow: 0 0 10px rgba(251, 146, 60, 0.9); }

/* hover tooltip over the globe */
.planet-tip {
    position: absolute;
    transform: translate(-50%, -130%);
    background: rgba(10, 14, 25, 0.94);
    border: 1px solid rgba(165, 210, 255, 0.28);
    color: #eaf2ff;
    font-size: 12.5px;
    line-height: 1.4;
    padding: 7px 11px;
    border-radius: 8px;
    pointer-events: none;
    white-space: nowrap;
    z-index: 5;
}

/* live ticker over the globe — like a broadcast feed, lower left */
.planet-ticker {
    position: absolute;
    left: clamp(14px, 2.5vw, 44px);
    bottom: clamp(14px, 3vh, 40px);
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    gap: 7px;
    max-width: min(44%, 380px);
    z-index: 4;
    pointer-events: none;
}
.planet-ticker-item {
    display: flex;
    align-items: flex-start;
    gap: 8px;
    padding: 9px 13px;
    border-radius: 13px;
    background: rgba(12, 16, 28, 0.48);
    border: 1px solid rgba(255, 255, 255, 0.09);
    backdrop-filter: blur(16px) saturate(1.35);
    -webkit-backdrop-filter: blur(16px) saturate(1.35);
    box-shadow: 0 8px 24px -14px rgba(0, 0, 0, 0.6);
    color: rgba(245, 245, 247, 0.85);
    font-size: 12px;
    line-height: 1.45;
    animation: tickerIn 0.5s ease;
}
.planet-ticker-item b { color: #ffffff; font-weight: 600; }
.planet-ticker-item i {
    flex-shrink: 0;
    margin-top: 5px;
    width: 6px;
    height: 6px;
    border-radius: 50%;
    background: #34d399;
    box-shadow: 0 0 7px rgba(52, 211, 153, 0.9);
    animation: planetPulse 1.6s infinite;
}
.planet-ticker-item.is-you { border-color: rgba(245, 217, 143, 0.35); }
.planet-ticker-item.is-you i { background: #f5d98f; box-shadow: 0 0 7px rgba(245, 217, 143, 0.9); }
.planet-ticker-item.is-footprint { color: rgba(245, 245, 247, 0.62); }
.planet-ticker-item.is-footprint i { background: rgba(150, 200, 250, 0.7); box-shadow: none; animation: none; }
.planet-ticker-item.is-download { border-color: rgba(196, 181, 253, 0.32); }
.planet-ticker-item.is-download i {
    background: #c4b5fd;
    box-shadow: 0 0 8px rgba(196, 181, 253, 0.85);
    animation: none;
}
@keyframes tickerIn {
    from { opacity: 0; transform: translateY(10px); }
    to { opacity: 1; transform: translateY(0); }
}
@media (prefers-reduced-motion: reduce) {
    .planet-ticker-item { animation: none; }
    .planet-ticker-item i { animation: none; }
}

/* "Right now" activity stream */
.planet-now { margin-top: 28px; }
.planet-now-title {
    font-size: 11.5px;
    letter-spacing: 0.16em;
    text-transform: uppercase;
    color: rgba(245, 245, 247, 0.4);
    margin: 0 0 12px;
}
.planet-now ul {
    list-style: none;
    margin: 0;
    padding: 0;
    display: flex;
    flex-direction: column;
    gap: 9px;
    align-items: center;
}
.planet-now li {
    display: inline-flex;
    align-items: center;
    gap: 9px;
    font-size: 14px;
    line-height: 1.5;
    color: rgba(245, 245, 247, 0.72);
}
.planet-now li b { color: #ffffff; font-weight: 600; }
.planet-now li i {
    flex-shrink: 0;
    width: 7px;
    height: 7px;
    border-radius: 50%;
    background: #bfe6ff;
    box-shadow: 0 0 9px rgba(190, 230, 255, 0.9);
    animation: planetPulse 2.2s infinite;
}
.planet-now li.is-you i { background: #f5d98f; box-shadow: 0 0 9px rgba(245, 217, 143, 0.9); }
.planet-now li.is-quiet { color: rgba(245, 245, 247, 0.46); }
.planet-now li.is-quiet i { display: none; }
.planet-now li.is-footprint { color: rgba(245, 245, 247, 0.52); font-size: 13.5px; }
.planet-now li.is-footprint i {
    background: rgba(150, 200, 250, 0.75);
    box-shadow: 0 0 5px rgba(150, 200, 250, 0.5);
    animation: none;
}

@keyframes planetPulse {
    0%, 100% { opacity: 1; }
    50% { opacity: 0.4; }
}
@media (prefers-reduced-motion: reduce) {
    .planet-now li i, .planet-key-live { animation: none; }
}


.planet-fineprint {
    margin: 24px auto 0;
    max-width: 560px;
    font-size: 11.5px;
    line-height: 1.6;
    color: rgba(245, 245, 247, 0.34);
}

/* --------------------------------------------------- annual letter */
.planet-letter-band { background: var(--bg-tint); border-top: 1px solid var(--line); }
.planet-letter { max-width: 720px; }
.planet-letter .lead { margin-top: 14px; max-width: 620px; }
.planet-letter-note {
    margin: 18px 0 22px;
    font-size: 15px;
    font-weight: 500;
    color: var(--ink);
}

@media (max-width: 800px) {
    .planet-privacy-grid { grid-template-columns: 1fr; }
    .planet-viewport { height: clamp(460px, 78vh, 700px); }
}

/* ------------------------------------------------------ guest wall */
.planet-wall[hidden] { display: none; }
.planet-wall { display: grid; gap: 30px; }
.planet-wall-head {
    display: grid;
    grid-template-columns: minmax(0, 0.9fr) minmax(0, 1.1fr);
    gap: 16px 56px;
    align-items: end;
}
.planet-wall-head > p { font-size: 17px; line-height: 1.62; color: var(--ink-2); max-width: 520px; margin: 0; }
.wall-notes {
    display: flex;
    gap: 14px;
    overflow-x: auto;
    scroll-snap-type: x mandatory;
    padding-bottom: 12px;
    -webkit-overflow-scrolling: touch;
    scrollbar-width: thin;
    scrollbar-color: var(--line-2) transparent;
}
.wall-notes::-webkit-scrollbar { height: 6px; }
.wall-notes::-webkit-scrollbar-thumb { background: var(--line-2); border-radius: 3px; }
.wall-notes:empty { display: none; }
.wall-note {
    flex: 0 0 min(300px, 80vw);
    scroll-snap-align: start;
}
.wall-empty { grid-column: 1 / -1; font-size: 15px; color: var(--ink-3); margin: 0; }
.wall-note {
    margin: 0;
    padding: 18px 20px;
    border: 1px solid var(--line);
    border-radius: 14px;
    background: var(--bg);
    transition: border-color 0.3s ease, box-shadow 0.3s ease;
}
.wall-note.is-highlit { border-color: rgba(214, 178, 90, 0.7); box-shadow: 0 0 0 3px rgba(245, 217, 143, 0.25); }
.wall-note blockquote { margin: 0 0 10px; font-size: 15px; line-height: 1.6; color: var(--ink); }
.wall-note figcaption { font-size: 12.5px; color: var(--ink-3); }
.wall-note .wall-replies { margin: 12px 0 0; padding: 10px 0 0 14px; border-left: 2px solid var(--line); display: grid; gap: 10px; }
.wall-note .wall-reply p { margin: 0; font-size: 13.5px; line-height: 1.55; color: var(--ink-2); }
.wall-note .wall-reply span { font-size: 11.5px; color: var(--ink-3); }
.wall-note .wall-reply-btn {
    margin-top: 12px;
    background: none;
    border: none;
    padding: 0;
    font: 500 12.5px var(--font);
    color: var(--ink-2);
    cursor: pointer;
    text-decoration: underline;
    text-underline-offset: 3px;
}
.wall-note .wall-reply-btn:hover { color: var(--ink); }

.wall-form { max-width: 720px; }
.wall-form label {
    display: block;
    font-size: 13.5px;
    font-weight: 500;
    color: var(--ink);
    margin-bottom: 14px;
}
.wall-form label span { color: var(--ink-3); font-weight: 400; }
.wall-form input, .wall-form textarea {
    display: block;
    width: 100%;
    margin-top: 7px;
    padding: 10px 13px;
    font: inherit;
    font-size: 15px;
    color: var(--ink);
    background: var(--bg);
    border: 1px solid var(--line-2);
    border-radius: 10px;
    resize: vertical;
}
.wall-form input:focus, .wall-form textarea:focus { outline: 2px solid var(--ink); outline-offset: 1px; }
.wall-form-row { display: grid; grid-template-columns: 1fr 1fr auto; gap: 0 16px; align-items: end; }
.wall-form-row .btn { margin-bottom: 14px; }
.wall-form-status { margin-top: 4px; font-size: 14px; color: var(--ink-2); min-height: 1.4em; }

@media (max-width: 720px) {
    .planet-wall-head { grid-template-columns: 1fr; align-items: start; }
    .wall-form-row { grid-template-columns: 1fr; }
    .wall-form-row .btn { margin-bottom: 0; justify-self: start; }
}

/* links inside ticker capsules — follow where others went */
.planet-ticker-item a {
    color: #ffffff;
    text-decoration: underline;
    text-decoration-color: rgba(165, 210, 255, 0.45);
    text-underline-offset: 2px;
    pointer-events: auto;
}
.planet-ticker-item a:hover { text-decoration-color: #f5d98f; }

/* ------------------------------------------------- subscribe (letters) */
.planet-subscribe { margin-top: 20px; max-width: 520px; }
.planet-subscribe-row { display: flex; gap: 10px; }
.planet-subscribe-row input {
    flex: 1;
    padding: 11px 15px;
    font: inherit;
    font-size: 15px;
    color: var(--ink);
    background: var(--bg);
    border: 1px solid var(--line-2);
    border-radius: 999px;
}
.planet-subscribe-row input:focus { outline: 2px solid var(--ink); outline-offset: 1px; }
.planet-subscribe-note { margin: 12px 0 0; font-size: 13.5px; color: var(--ink-3); }
@media (max-width: 560px) {
    .planet-subscribe-row { flex-direction: column; }
}

/* quick phrases + diner-card wall additions */
.wall-quick { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; }
.wall-quick-label { font-size: 13px; color: var(--ink-3); margin-right: 2px; }
.wall-quick button {
    padding: 7px 14px;
    border-radius: 999px;
    border: 1px solid var(--line-2);
    background: var(--bg);
    color: var(--ink);
    font: 500 13px var(--font);
    cursor: pointer;
    transition: transform 0.15s ease, border-color 0.15s ease, background 0.15s ease;
}
.wall-quick button:hover { transform: translateY(-1px) scale(1.03); border-color: var(--ink); }
.wall-quick button.is-sent { background: var(--ink); color: #fff; border-color: var(--ink); }
.wall-note.is-mine { border-color: rgba(214, 178, 90, 0.65); background: rgba(245, 217, 143, 0.07); }
.wall-form-actions { display: flex; align-items: center; gap: 16px; }
.wall-form-alt { margin-top: 16px; font-size: 13px; color: var(--ink-3); }

/* fixes: the borrowed hidden-label class, and the wrapping button */
.co-visually-hidden {
    position: absolute;
    width: 1px;
    height: 1px;
    margin: -1px;
    padding: 0;
    overflow: hidden;
    clip: rect(0 0 0 0);
    white-space: nowrap;
    border: 0;
}
.planet-subscribe-row .btn { white-space: nowrap; }

/* Say more… opens the card dialog */
.wall-say-more { border-style: dashed; }
.wall-dialog {
    border: none;
    border-radius: 18px;
    padding: 0;
    max-width: 560px;
    width: calc(100% - 40px);
    box-shadow: 0 24px 80px rgba(8, 10, 18, 0.3);
}
.wall-dialog::backdrop {
    background: rgba(8, 10, 18, 0.55);
    backdrop-filter: blur(3px);
    -webkit-backdrop-filter: blur(3px);
}
.wall-dialog .wall-form { padding: 24px 28px 26px; max-width: none; }
.wall-dialog-head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 18px;
}
.wall-dialog-head h3 { margin: 0; font-size: 18px; letter-spacing: -0.01em; color: var(--ink); }
.wall-dialog-close {
    background: none;
    border: none;
    padding: 4px 8px;
    font-size: 15px;
    color: var(--ink-3);
    cursor: pointer;
}
.wall-dialog-close:hover { color: var(--ink); }

.planet-letter-ps {
    margin-top: 22px;
    font-size: 13.5px;
    line-height: 1.6;
    color: var(--ink-3);
}
.planet-letter-ps a { color: var(--ink-2); text-underline-offset: 3px; }
.planet-letter-ps a:hover { color: var(--ink); }

/* ---------------------------------------------- home-page live planet */
.home-planet { padding: clamp(48px, 7vw, 88px) 0 clamp(40px, 6vw, 72px); }
.home-planet-head {
    text-align: center;
    margin-bottom: clamp(20px, 3vw, 36px);
    position: relative;
    z-index: 2;
}
.home-planet-head .eyebrow { color: #f5d98f; }
.home-planet-head .h2 {
    color: #f5f5f7;
    max-width: 640px;
    margin: 10px auto 0;
}
.home-planet .planet-viewport { height: auto; }
.home-planet-wrap {
    width: auto;
    max-width: min(640px, 78vh);
    height: auto;
    margin: 0 auto;
    padding: 0 24px;
    overflow: visible;
}
.home-planet-wrap canvas {
    height: auto;
    aspect-ratio: 1 / 1;
}
.home-planet-enter {
    position: absolute;
    inset: 0;
    display: flex;
    align-items: flex-end;
    justify-content: center;
    padding-bottom: clamp(18px, 3vh, 34px);
    text-decoration: none;
    z-index: 5;
    cursor: pointer;
}
.home-planet-enter span {
    padding: 10px 18px;
    border-radius: 999px;
    background: rgba(10, 14, 25, 0.72);
    border: 1px solid rgba(165, 210, 255, 0.3);
    color: #eaf2ff;
    font: 500 13.5px/1 var(--font);
    backdrop-filter: blur(6px);
    -webkit-backdrop-filter: blur(6px);
    transition: transform 0.25s ease, border-color 0.25s ease;
}
.home-planet-enter:hover span {
    transform: translateY(-2px);
    border-color: rgba(245, 217, 143, 0.6);
}
/* the cinematic dive */
.home-planet .planet-canvas-wrap {
    transition: transform 0.75s cubic-bezier(0.4, 0, 0.2, 1), opacity 0.7s ease;
}
.home-planet.is-zooming .planet-canvas-wrap {
    transform: scale(1.6);
    opacity: 0;
}
.home-planet.is-zooming .home-planet-enter span,
.home-planet.is-zooming .home-planet-head {
    opacity: 0;
    transition: opacity 0.4s ease;
}
@media (prefers-reduced-motion: reduce) {
    .home-planet .planet-canvas-wrap { transition: none; }
}

/* The bridge: after the globe, three doors into the rest of the site. */
.planet-bridge-head h2 { max-width: 600px; margin-top: 12px; }
.planet-bridge-grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 14px;
    margin-top: 30px;
}
.planet-bridge-card {
    display: block;
    padding: 22px 24px;
    border: 1px solid var(--line);
    border-radius: 16px;
    background: var(--bg);
    transition: transform 0.25s var(--ease), box-shadow 0.25s var(--ease);
}
.planet-bridge-card:hover {
    transform: translateY(-3px);
    box-shadow: 0 14px 34px -20px rgba(0, 0, 0, 0.3);
}
.planet-bridge-card h3 { font-size: 16.5px; font-weight: 600; letter-spacing: -0.015em; }
.planet-bridge-card p { margin-top: 8px; font-size: 13.5px; line-height: 1.55; color: var(--ink-2); }
@media (max-width: 720px) {
    .planet-bridge-grid { grid-template-columns: 1fr; }
}
