*{box-sizing:border-box}body{margin:0;background:#f3f7fc;color:#112d50;font-family:-apple-system,BlinkMacSystemFont,"Hiragino Kaku Gothic ProN",sans-serif;padding-bottom:95px}header{height:77px;padding:calc(env(safe-area-inset-top) + 13px) 18px 12px;background:#fff;display:flex;align-items:center;justify-content:space-between;border-bottom:1px solid #e5edf7;position:sticky;top:0;z-index:5}.brand{display:flex;gap:10px;align-items:center}.brand b{font-size:17px;letter-spacing:.06em}.brand small{display:block;font-size:9px;color:#7e93a9;letter-spacing:.16em}.mark{display:grid;place-items:center;background:#0b4da5;color:white;font-size:24px;font-weight:900;width:39px;height:39px;border-radius:11px}.version{font-size:10px;color:#8397b1}main{max-width:720px;margin:auto;padding:22px 15px}.page{display:none}.page.active{display:block}.eyebrow{font-size:10px;letter-spacing:.22em;color:#0e6bd2;font-weight:800}h1{font-size:25px;margin:7px 0 20px}.datebar{display:flex;gap:10px;margin-bottom:16px}.datebar input,.datebar button{border:1px solid #d9e6f5;border-radius:12px;background:white;padding:12px;font-size:14px;color:#174b8b}.datebar input{flex:1;min-width:0}.datebar button{font-weight:700}.statline{display:grid;grid-template-columns:repeat(3,1fr);gap:9px;margin-bottom:25px}.statline>div{background:#fff;border:1px solid #e3ecf8;border-radius:14px;padding:13px 10px;min-width:0}.statline small{display:block;color:#8296ac;font-size:10px}.statline strong{font-size:19px;display:block;margin-top:6px}.statline #status{font-size:12px}.sectiontitle{font-size:11px;letter-spacing:.13em;font-weight:800;color:#849bb3;margin-bottom:12px}.venues{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:8px}.venue{border:1px solid #e0eaf5;background:#fff;border-radius:13px;min-height:95px;padding:10px 4px;text-align:center;color:#183b68;box-shadow:0 2px 9px #153f6a07}.venue .num{font-size:10px;color:#8da3bd}.venue strong{display:block;font-size:15px;margin:7px 0}.venue .state{font-size:10px;color:#0b70c7}.venue.off{background:#edf1f6;color:#9aa9b9;box-shadow:none}.venue.off .state{color:#a6b2be}.venue.live{border-top:3px solid #1269d1}.content-card{background:white;border:1px solid #e1eaf5;border-radius:18px;padding:17px;margin-top:15px}.content-card h2{font-size:16px}.content-card p{font-size:13px;line-height:1.8;color:#58718e}.back{border:0;background:none;color:#1768bd;font-weight:700;margin-bottom:20px}.race-tabs{display:grid;grid-template-columns:repeat(6,1fr);gap:6px}.race-tabs button{border:1px solid #dce7f3;background:white;border-radius:9px;padding:12px 2px;color:#32567d}.race-tabs button.selected{background:#0b4da5;color:white}.lane{display:grid;grid-template-columns:37px 1fr;align-items:center;border-bottom:1px solid #e9eff6;padding:12px 0;gap:10px}.lane:last-child{border:0}.lane .boat{width:35px;height:35px;border-radius:9px;display:grid;place-items:center;font-weight:900;border:1px solid #d6e2ef}.lane:nth-child(2) .boat{background:#1b2737;color:white}.lane:nth-child(3) .boat{background:#e52c39;color:white}.lane:nth-child(4) .boat{background:#2861d2;color:white}.lane:nth-child(5) .boat{background:#f6d23e;color:#222}.lane:nth-child(6) .boat{background:#22a267;color:white}.lane strong{font-size:14px}.lane small{display:block;color:#8298b0;font-size:11px;margin-top:3px}nav{position:fixed;bottom:0;left:0;right:0;display:flex;justify-content:space-around;background:#fff;border-top:1px solid #dbe7f5;padding:8px 10px calc(8px + env(safe-area-inset-bottom));z-index:10}nav button{border:0;background:none;color:#8497ae;font-size:11px;min-width:70px}nav button span{display:block;font-size:23px;margin-bottom:3px}nav button.on{color:#095bb9;font-weight:800}@media(max-width:360px){.venues{gap:5px}.venue strong{font-size:13px}.venue{min-height:87px}}
/* v0.19.1 home rebuilt from user reference */
body{background:#f5f5fa;color:#121b2a}header{background:linear-gradient(110deg,#07529b,#0088c5);color:#fff;border:0;height:83px;padding:calc(env(safe-area-inset-top) + 10px) 16px 12px}.brand b{font-size:21px;font-weight:900;letter-spacing:-.05em}.brand small{color:#d4eefa;font-size:9px}.mark{background:#fff;color:#0a5ca5;border-radius:50%;font-family:Georgia,serif}.head-actions{display:flex;align-items:center;gap:10px}.head-actions button{background:none;border:0;color:white;font-size:29px}.version{color:#d4ebfa}main{padding:0 0 25px;max-width:720px}.dashboard-top{background:linear-gradient(110deg,#07529b,#0088c5);padding:9px 15px 17px}.dashboard-top:after{content:'';display:block;clear:both}.dash-heading{background:#fff;border-radius:15px 15px 0 0;display:flex;align-items:center;gap:12px;padding:16px 15px 7px}.dash-emblem{background:#102e50;color:#f9c954;border:3px solid #c6a65b;border-radius:50%;width:49px;height:49px;display:grid;place-items:center;font:900 28px Georgia,serif}.dash-user strong{display:block;font-size:16px}.dash-user small{font-size:10px;color:#7c94ac}.dash-metrics{background:white;border-radius:0 0 15px 15px;display:grid;grid-template-columns:repeat(4,1fr);padding:7px 8px 13px;gap:5px}.dash-metrics>div{text-align:center;border-radius:9px;background:#f5f7fb;padding:7px 1px}.dash-metrics small{display:block;font-size:9px;color:#8b9aac}.dash-metrics strong{font-size:17px;color:#ff852e}.dash-metrics>div:nth-child(2) strong{color:#138bd0}.dash-metrics b{font-size:13px}.race-heading{padding:19px 14px 12px;display:flex;align-items:center;justify-content:space-between;gap:8px}.race-heading h1{margin:0;font-size:23px;color:#101010}.datebar{margin:0;gap:5px}.datebar input{max-width:120px;padding:7px 4px;font-size:11px}.datebar button{padding:6px 10px}.venues{padding:0 12px;grid-template-columns:repeat(4,minmax(0,1fr));gap:9px}.venue{min-height:104px;border-radius:14px;text-align:left;padding:11px 7px 8px 10px;box-shadow:0 3px 9px #182b4b0b;position:relative;border:1px solid #e5e9f0}.venue:before{content:'';position:absolute;left:6px;top:14px;bottom:13px;width:4px;background:#15c4e2;border-radius:5px}.venue .num{display:none}.venue strong{font-size:16px;color:#111;margin:3px 0 10px;padding-left:6px;white-space:nowrap}.venue .state{display:block;font-size:10px;color:#333;padding-left:6px;line-height:1.6}.venue .time{display:block;font-size:11px;color:#111;font-weight:800;padding-left:6px;white-space:nowrap}.venue.off{background:#f3f4f8;opacity:.52}.venue.off:before{background:#d5d8df}.venue.off strong,.venue.off .state,.venue.off .time{color:#adb3bd}.venue.morning:before{background:#ff912e}.venue.summer:before{background:#5a8df6}.venue.day:before{background:#00c1df}.venue.night:before{background:#c832dc}.venue.midnight:before{background:#1237c7}.venue.off{pointer-events:none}.legend{background:#fff;border-radius:14px;margin:15px 12px 0;padding:13px;display:flex;flex-wrap:wrap;gap:12px;font-size:11px;color:#84909b}.legend span{display:flex;align-items:center;gap:5px}.legend i{width:10px;height:10px;border-radius:50%;display:inline-block}.legend .morning{background:#ff912e}.legend .summer{background:#5a8df6}.legend .day{background:#00c1df}.legend .night{background:#c832dc}.legend .midnight{background:#1237c7}.data-note{font-size:11px;color:#8a98a7;margin:12px 15px}nav{background:#07152e;color:white;border:0}nav button{color:#c5ccda}nav button.on{color:#3ea6ff}@media(max-width:390px){.venues{gap:6px;padding:0 9px}.venue{padding-left:8px}.venue strong{font-size:14px}.venue .state,.venue .time{font-size:9px}}
/* v0.19.2: fixed header + daily data, safe-area-aware scrolling */
html{height:100%;overflow:hidden}
body{height:100dvh;min-height:100%;overflow:hidden;padding:0;background:#f5f5fa}
.fixed-top{position:fixed;top:env(safe-area-inset-top,0px);left:0;right:0;z-index:30;background:linear-gradient(110deg,#07529b,#0088c5);box-shadow:0 2px 8px #0b36651a}
.fixed-top header{position:relative;top:auto;height:68px;padding:10px 16px 8px}
.fixed-top .dashboard-top{padding:5px 14px 15px}
.fixed-top .dash-panel{background:#fff;border-radius:16px;display:flex;align-items:center;padding:12px 10px;gap:8px;min-height:96px}
.fixed-top .dash-heading{border-radius:0;padding:0 10px 0 0;flex:1.12;min-width:0;gap:8px;border-right:1px solid #dce1e8}
.fixed-top .dash-emblem{width:43px;height:43px;flex:none;font-size:24px}
.fixed-top .dash-user{min-width:0;flex:1}
.fixed-top .dash-user strong{font-size:14px;white-space:nowrap}
.fixed-top .dash-user small{font-size:9px;display:block;margin:3px 0 6px}
.fixed-top .dash-progress{height:7px;background:#e9eaf0;border-radius:9px;width:100%}
.fixed-top .dash-metrics{flex:1.15;grid-template-columns:repeat(2,minmax(0,1fr));padding:0;gap:5px;background:transparent}
.fixed-top .dash-metrics>div{padding:3px 1px;background:transparent}
.fixed-top .dash-metrics small{font-size:9px;white-space:nowrap}
.fixed-top .dash-metrics strong{font-size:17px}
.fixed-top .dash-metrics b{font-size:10px}
main{position:absolute;top:calc(env(safe-area-inset-top,0px) + 187px);bottom:calc(env(safe-area-inset-bottom,0px) + 68px);left:0;right:0;overflow-y:auto;overflow-x:hidden;overscroll-behavior:contain;-webkit-overflow-scrolling:touch;max-width:none;padding:0 0 18px}
nav{height:68px;bottom:env(safe-area-inset-bottom,0px);padding:7px 10px;z-index:40}
body:before{content:'';position:fixed;top:0;left:0;right:0;height:env(safe-area-inset-top,0px);background:#f5f5fa;z-index:50}
body:after{content:'';position:fixed;bottom:0;left:0;right:0;height:env(safe-area-inset-bottom,0px);background:#07152e;z-index:50}
@media(max-width:380px){.fixed-top .dash-panel{padding:9px 7px;gap:5px}.fixed-top .dash-heading{gap:5px;padding-right:6px}.fixed-top .dash-emblem{width:35px;height:35px;font-size:20px}.fixed-top .dash-user strong{font-size:12px}.fixed-top .dash-metrics small{font-size:8px}}

/* v0.19.3 compact bottom safe area */
nav{height:55px;bottom:env(safe-area-inset-bottom,0px);padding:4px 8px;align-items:center}
nav button{font-size:10px;line-height:1.1}
nav button span{font-size:19px;margin-bottom:2px}
main{bottom:calc(env(safe-area-inset-bottom,0px) + 55px)}
body:after{background:#07152e}

/* v0.19.4: eliminate oversized footer and home-only banner */
:root{--nav-height:52px}
nav{position:fixed;bottom:0;left:0;right:0;height:calc(var(--nav-height) + env(safe-area-inset-bottom,0px));padding:4px 8px env(safe-area-inset-bottom,0px);box-sizing:border-box;align-items:center}
main{bottom:calc(var(--nav-height) + env(safe-area-inset-bottom,0px))}
body:after{display:none!important}
body.detail-mode .fixed-top{display:none!important}
body.detail-mode main{top:env(safe-area-inset-top,0px);padding-top:8px;background:#f1f5fb}
body.detail-mode .page{padding:0 12px}
.detail-head{display:flex;align-items:center;justify-content:space-between;gap:10px;background:#fff;border:1px solid #d9e5f4;border-radius:12px;padding:10px;margin:2px 0 12px}
.detail-head strong{font-size:16px}.detail-head .back{margin:0;padding:4px;border:0;font-size:12px;white-space:nowrap}.detail-tag{font-size:10px;color:#1c67b6;white-space:nowrap}
.race-tabs{display:grid;grid-template-columns:repeat(6,minmax(0,1fr));gap:5px;margin-bottom:15px}.race-tabs button{padding:10px 0;font-size:12px}
.entry-header{background:#fff;border:1px solid #dce7f5;border-radius:13px 13px 0 0;padding:14px 12px 10px;color:#073f90;font-size:16px;font-weight:800}
.entry-switch{display:grid;grid-template-columns:1fr 1fr;margin-top:12px;border:1px solid #cbdcf0;border-radius:9px;overflow:hidden}
.entry-switch button{border:0;background:#edf3fc;color:#355c85;padding:11px;font-weight:800}.entry-switch button.selected{background:#0757b4;color:#fff}
#detail .content-card{border-radius:0 0 13px 13px;margin:0;padding:12px 10px;border-top:0}
.race-caption{font-weight:800;color:#174f9c;font-size:12px;margin:0 0 8px}
.racer-card{border:2px solid #163c7d;border-radius:10px;overflow:hidden;margin-bottom:12px;background:#fff}
.racer-main{display:flex;min-height:95px}.racer-lane{width:53px;display:flex;flex-direction:column;justify-content:center;align-items:center;flex-shrink:0;background:#fff;color:#111}.racer-lane b{font-size:32px;line-height:1}.racer-lane small{font-size:11px}.racer-lane.lane-2{background:#232936;color:#fff}.racer-lane.lane-3{background:#e52e39;color:#fff}.racer-lane.lane-4{background:#1766c8;color:#fff}.racer-lane.lane-5{background:#f8d531;color:#111}.racer-lane.lane-6{background:#229b50;color:#fff}
.racer-info{flex:1;min-width:0;padding:13px 7px}.racer-info strong{display:block;color:#0c4f9d;font-size:15px;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}.racer-tags{display:flex;flex-wrap:wrap;gap:6px;margin-top:12px}.racer-tags span{background:#eaf2fd;border-radius:5px;padding:4px;font-size:10px;font-weight:700}
.motor-info{width:95px;border-left:1px solid #dce6f2;padding:11px 5px;text-align:center;display:flex;flex-direction:column;justify-content:center;gap:5px}.motor-info small{font-size:10px;color:#174d93;font-weight:700}.motor-info b{font-size:20px}
.racer-sub{display:grid;grid-template-columns:repeat(4,1fr);border-top:2px solid #173e82}.racer-sub span{text-align:center;padding:9px 1px;border-right:1px solid #d1dce9;color:#0c4c96;font-size:10px;font-weight:700}.racer-sub span:last-child{border:0}.racer-sub b{display:block;margin-top:5px;color:#172d49;font-size:13px}

/* v0.19.5 iPhone bottom viewport correction */
html,body{height:100%;height:100dvh}
body{background:#07152e}
main{bottom:calc(57px + env(safe-area-inset-bottom,0px));background:#f1f5fb}
nav{position:fixed!important;bottom:0!important;height:calc(57px + env(safe-area-inset-bottom,0px))!important;padding:5px 10px max(5px,env(safe-area-inset-bottom,0px))!important;background:#07152e!important;align-items:flex-start!important}
nav button{height:50px}
body:after{display:none!important}
.racer-info{min-width:0}.racer-info strong{font-size:15px}.rank-line{display:flex;gap:5px;align-items:center;margin-top:7px}.rank-line small{font-size:10px;color:#55729a}
.score-pill{display:inline-block;padding:4px 7px;border-radius:6px;font-weight:900;color:#fff;font-size:12px;white-space:nowrap}
.score-A{background:#e33d42}.score-B{background:#36a75a}.score-C{background:#efb52d;color:#172944}.score-D{background:#3296d5}.score-pill.unknown{background:#9cacc0}
.motor-info .score-pill{margin:5px 0}.motor-info small{font-size:10px}
.reference-notice{font-size:10px!important;line-height:1.6!important;background:#eef5ff;border-radius:8px;padding:8px;margin:6px 0 13px!important}

/* v0.19.6 compact true viewport navigation; only safe inset below icons */
:root{--bottom-nav-content:48px}
html,body{height:100%;height:100dvh;margin:0;overflow:hidden}
body{background:#f1f5fb}
nav{position:fixed!important;bottom:0!important;top:auto!important;height:calc(var(--bottom-nav-content) + env(safe-area-inset-bottom,0px))!important;padding:2px 6px env(safe-area-inset-bottom,0px)!important;align-items:center!important;justify-content:space-around!important;box-sizing:border-box!important}
nav button{height:44px!important;min-height:0!important;line-height:1!important;padding:1px 0!important}
nav button span{font-size:18px!important;margin:0 0 3px!important}
main{bottom:calc(var(--bottom-nav-content) + env(safe-area-inset-bottom,0px))!important}
body:after{display:none!important}
.score-S{background:linear-gradient(115deg,#9b6a0c,#e6bb40);color:#fff}
.score-evolution{display:flex;flex-wrap:wrap;gap:5px;margin-top:7px;font-size:10px;color:#637a99}.score-evolution span{background:#eef4fd;padding:4px 5px;border-radius:5px}.score-evolution b{color:#183e78}.score-evolution b.plus{color:#15985c}.score-evolution b.minus{color:#d64b53}
/* v0.19.27: event grade styling, preserving existing general-event cards */
.venue.live.grade-gold{border-top-color:#d6a52a;border-color:#e5c46e;background:linear-gradient(160deg,#fff9e9 0%,#fff 75%);box-shadow:0 2px 9px #9b76151c}
.venue.live.grade-gold .state{color:#9a6c08}
.venue.live.grade-silver{border-top-color:#8798b0;border-color:#bdc9d6;background:linear-gradient(160deg,#f1f4f8 0%,#fff 78%);box-shadow:0 2px 9px #52657816}
.venue.live.grade-silver .state{color:#5d6c81}
.racer-name .female-heart{display:inline-block;color:#ed4e85;font-size:.85em;margin-left:6px;vertical-align:baseline;line-height:1}

/* v0.19.28: clearly visible race grade card backgrounds, preserve general race styling */
.venue.live.grade-gold{background:linear-gradient(145deg,#ffdf77 0%,#f2bc3b 48%,#fff0b8 100%)!important;border:2px solid #c38b17!important;border-top:4px solid #a36a08!important;box-shadow:0 3px 11px #a67b3650!important}
.venue.live.grade-gold strong,.venue.live.grade-gold .time{color:#4a3100!important}
.venue.live.grade-gold .state{color:#72500c!important}
.venue.live.grade-silver{background:linear-gradient(145deg,#e1e8f1 0%,#bac6d5 52%,#f1f4f8 100%)!important;border:2px solid #8999ae!important;border-top:4px solid #65758b!important;box-shadow:0 3px 11px #63758b3d!important}
.venue.live.grade-silver strong,.venue.live.grade-silver .time{color:#23374f!important}
.venue.live.grade-silver .state{color:#3c536d!important}
.racer-name .female-heart{display:inline!important;color:#f23b86!important;font-size:18px!important;margin-left:7px!important}

/* v0.19.29: brighter pearl-silver grade cards */
.venue.live.grade-silver{background:linear-gradient(145deg,#ffffff 0%,#f4f7fb 40%,#e5ebf2 75%,#ffffff 100%)!important;border:2px solid #a9b5c5!important;border-top:4px solid #a6b4c7!important;box-shadow:0 3px 10px #73839a24!important}
.venue.live.grade-silver strong,.venue.live.grade-silver .time{color:#243951!important}
.venue.live.grade-silver .state{color:#586a80!important}

/* v0.19.30: vertical venue race listing */
.venue-detail-banner{background:linear-gradient(115deg,#0753a8,#069bd1);color:#fff;margin:0 -12px 18px}.venue-detail-actions{display:flex;gap:10px;padding:14px 15px 6px;background:#f3f5fb}.venue-detail-actions button{width:45px;height:45px;border-radius:50%;background:#fff;border:0;font-size:31px;color:#172b4b}.venue-detail-title{display:flex;align-items:center;gap:10px;padding:14px 16px 18px}.venue-detail-title strong{font-size:24px;flex:1}.venue-detail-title span{background:#ffffff24;border-radius:7px;padding:4px 8px}.venue-detail-title button{background:white;color:#0983b8;border:0;border-radius:10px;padding:10px;font-weight:800}.venue-detail-title #venueReload{font-size:23px;padding:4px 10px}.venue-menu{display:grid;grid-template-columns:repeat(3,1fr);background:#e9edf5}.venue-menu button{border:0;background:transparent;color:#2788bd;padding:15px 1px;font-weight:800}.venue-menu button.on{background:#0879bd;color:white}.race-list{padding:0 0 18px}.venue-race{background:white;border-radius:15px;overflow:hidden;border:1px solid #d7e3f2;margin:0 0 22px;box-shadow:0 3px 12px #142e5614}.venue-race-head{background:linear-gradient(110deg,#0753a8,#0899ce);color:#fff;display:flex;align-items:center;gap:9px;padding:17px 13px;font-weight:800}.venue-race-head b{font-size:23px}.venue-race-head span{font-size:15px}.venue-race-head em{font-style:normal;color:#ff4e56;font-size:13px}.venue-race-head em.closed{color:#d8e5f3}.venue-entry-cols,.venue-entry-row{display:grid;grid-template-columns:38px minmax(0,1fr) 58px 66px;align-items:stretch;text-align:center}.venue-entry-cols{background:#e9e9eb;color:#8b8d95;font-size:10px;min-height:45px;align-items:center}.venue-entry-row{min-height:66px;border-bottom:1px solid #ddd}.venue-entry-lane{display:grid;place-items:center;font-size:22px;font-weight:800;color:#111;background:#fff}.venue-entry-lane.lane-2{background:#080808;color:#fff}.venue-entry-lane.lane-3{background:#ff303d;color:#fff}.venue-entry-lane.lane-4{background:#0d91e9;color:#fff}.venue-entry-lane.lane-5{background:#ffd300;color:#111}.venue-entry-lane.lane-6{background:#24c15a;color:#fff}.venue-entry-person{display:flex;flex-direction:column;justify-content:center;padding:4px;min-width:0}.venue-entry-person b{font-size:15px;color:#161616}.venue-entry-person small{font-size:10px;color:#90949c}.venue-entry-grade{align-self:center;justify-self:center;border:1px solid #ef7777;color:#e84c58;border-radius:7px;padding:5px;font-size:13px;font-weight:800}.venue-entry-motor{display:flex;flex-direction:column;justify-content:center;border-left:1px solid #ddd;font-weight:800}.venue-entry-motor b{font-size:18px;text-decoration:underline}.venue-entry-motor small{border-top:1px solid #ddd;font-size:13px;padding-top:3px}.venue-race-actions{display:grid;grid-template-columns:1fr 1fr 1.6fr;gap:8px;background:#e7f0ff;padding:13px}.venue-race-actions button{background:#fff;color:#1787b9;border:1px solid #53b3d9;border-radius:12px;font-weight:800;padding:14px 2px}.venue-race-actions button:last-child{background:#078fc7;color:#fff}.female-heart{color:#ed4f92;margin-left:4px}

/* v0.19.34: motor/boat 2-ren rates and visible grade divider */
.venue-entry-cols,.venue-entry-row{grid-template-columns:34px minmax(0,1fr) 51px 54px 54px}
.venue-entry-grade{align-self:stretch;justify-self:stretch;display:flex;align-items:center;justify-content:center;border:0;border-left:1px solid #d1d8e3;border-right:1px solid #d1d8e3;border-radius:0;padding:3px 1px;font-size:12px;position:relative}
.venue-entry-grade::before{content:"";position:absolute;inset:calc(50% - 16px) 4px;border:1px solid #ef7777;border-radius:7px;pointer-events:none}
.venue-entry-motor,.venue-entry-boat{display:flex;flex-direction:column;justify-content:center;min-width:0;font-weight:800;border-left:1px solid #ddd}
.venue-entry-motor b,.venue-entry-boat b{font-size:16px;text-decoration:underline}
.venue-entry-motor small,.venue-entry-boat small{border-top:1px solid #ddd;font-size:11px;padding-top:3px}
.venue-entry-cols{font-size:9px}

/* v0.19.35: one consistent border at grade/motor boundary */
.venue-entry-grade{border-right:0}
.venue-entry-motor{border-left:1px solid #d1d8e3}
.venue-race-head{flex-wrap:wrap}
.race-result-button{margin-left:auto;border:1px solid #fff9;background:#fff;color:#0865a9;border-radius:9px;padding:7px 10px;font-size:12px;font-weight:800;white-space:nowrap}
.race-result-button:disabled{background:#d6e0ea;color:#69798c;border-color:#d6e0ea;opacity:1}
.race-result-panel{padding:12px;background:#f8fbff;border-top:1px solid #cddff1}
.race-result-panel[hidden]{display:none}
.race-result-panel h3{background:#078cdb;color:white;text-align:center;margin:12px 0 0;padding:10px;font-size:16px}
.result-pay-row,.result-finish-row,.result-start-row{display:grid;grid-template-columns:65px 1fr 100px;align-items:center;gap:8px;padding:9px 8px;border-bottom:1px solid #dce3ed;font-size:13px;background:#fff}
.result-pay-row:nth-of-type(even),.result-finish-row:nth-of-type(even),.result-start-row:nth-of-type(even){background:#edf2f7}
.result-pay-row strong{text-align:right}.result-finish-row{grid-template-columns:36px 32px 1fr 75px}.result-finish-row small{text-align:right}.result-start-row{grid-template-columns:32px 1fr 70px}.result-start-row b{text-align:right}
.result-lane{display:inline-grid;place-items:center;min-height:29px;background:#fff;color:#111;font-weight:800}.result-lane.lane-2{background:#111;color:#fff}.result-lane.lane-3{background:#f34;color:#fff}.result-lane.lane-4{background:#1497ee;color:#fff}.result-lane.lane-5{background:#ffd600}.result-lane.lane-6{background:#25bb60;color:#fff}
.result-empty{padding:12px;background:#fff;color:#677487}

/* v0.19.36 result-only enhancements */
.result-technique{display:flex;justify-content:space-between;align-items:center;padding:11px 14px;background:#e8f3ff;color:#153a65;font-weight:700;border-bottom:1px solid #d5e4f5}
.result-technique strong{color:#007bc0;font-size:16px}
.result-heading-note{float:right;font-size:11px;font-weight:500;opacity:.9}
.venue-entry-person .female-heart,.result-finish-row .female-heart,.result-start-row .female-heart{display:inline!important;color:#ef4085!important;font-size:16px!important;margin-left:5px}

.result-pay-row{display:grid!important;grid-template-columns:62px minmax(65px,1fr) auto 70px!important;align-items:center;gap:5px!important}.result-pay-row .result-popularity{text-align:right;color:#60748e;font-size:11px;white-space:nowrap}.result-technique strong{font-size:13px!important;text-align:right}

/* v0.19.39 prediction view (no synthetic betting tickets) */
.prediction-two-col{display:grid;grid-template-columns:1fr 1fr;gap:10px}.prediction-ticket{border:1px solid #d4e2f4;border-radius:12px;padding:12px;min-width:0;background:#f7faff}.prediction-ticket h3{font-size:15px;margin:0 0 12px;color:#163b71}.prediction-unavailable{font-size:12px;color:#60748b;line-height:1.6}.prediction-comment{margin-top:14px;border:1px solid #d4e2f4;border-radius:12px;padding:14px}.prediction-comment h3{margin:0 0 8px;color:#163b71}@media(max-width:360px){.prediction-two-col{gap:6px}.prediction-ticket{padding:8px}}

/* v0.19.42: isolated legacy engine view */
#legacy{padding:0!important;}
.legacy-header{display:flex;align-items:center;gap:12px;padding:10px 12px;background:#fff;color:#12376a;font-size:13px}
.legacy-header button,.legacy-launch{border:0;border-radius:8px;padding:12px 15px;background:#1765ba;color:white;font-weight:700;cursor:pointer}
#legacyFrame{display:block;width:100%;height:calc(100dvh - 205px);min-height:400px;border:0;background:#fff}

.legacy-status{padding:6px 14px;margin:0;font-size:12px;color:#244a78;background:#e9f3ff}

/* v0.19.45 direct legacy prediction */
#legacy{display:none!important}.prediction-source{font-size:12px;color:#4774a8;margin-bottom:12px}.prediction-score{display:flex;flex-wrap:wrap;gap:7px;margin:10px 0 16px}.prediction-score span{padding:6px 9px;border-radius:8px;background:#edf4ff;font-size:12px}.prediction-columns{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:10px}.prediction-columns section{min-width:0;background:#f4f8ff;border:1px solid #dce8fa;border-radius:12px;padding:10px 7px}.prediction-columns h3{font-size:14px;color:#163d77;margin:0 0 10px}.prediction-columns h3 small{display:block;font-size:10px;color:#6c829c;font-weight:normal}.prediction-ticket{display:flex;flex-wrap:wrap;align-items:center;justify-content:space-between;gap:3px;border-bottom:1px solid #dce6f4;padding:9px 2px;font-size:12px}.prediction-ticket b{font-size:15px;color:#113a7d}.prediction-ticket span{color:#526f91}.prediction-ticket strong{color:#165bb2}.prediction-reason{margin-top:16px;border:1px solid #dce8fa;border-radius:10px;padding:12px}.prediction-reason summary{font-weight:bold;cursor:pointer}.prediction-notice{font-size:12px;color:#8a6b35}@media(max-width:370px){.prediction-columns{gap:6px}.prediction-columns section{padding:8px 5px}.prediction-ticket b{font-size:13px}}

/* v0.19.46: reference-inspired compact 3-ren-tan / 2-ren-tan prediction layout */
#prediction{padding-left:10px;padding-right:10px}#prediction .eyebrow{display:none}#predictionHeading{text-align:center;font-size:19px;margin:9px 0 15px}#predictionBody{padding:0;background:transparent;border:0;box-shadow:none}
.pred-layout{display:grid;grid-template-columns:minmax(0,1fr) minmax(0,1fr);gap:9px;align-items:start}.pred-col,.pred-panel{min-width:0}.pred-panel{border:1px solid #d4e4f3;border-radius:15px;padding:10px 7px;background:#fff;box-shadow:0 3px 12px #102b4810}.pred-panel-tri{border-color:#f4d2d8}.pred-panel-pair{border-color:#cfe0f5}.pred-panel h2{font-size:16px;margin:0 0 4px;color:#172536;white-space:nowrap}.pred-panel h2 small{font-size:11px;color:#c63e4e}.pred-panel-pair h2 small{color:#2287c6}.pred-fire{color:#e32f45}.pred-blue{color:#158ccf}.pred-panel-sub{font-size:9px;line-height:1.4;color:#8092a7;margin-bottom:10px;min-height:26px}.pred-bets{display:grid;gap:5px}.pred-bet{display:flex;align-items:center;gap:3px;background:#f2f4f8;border:1px solid #e6e9f0;border-radius:8px;min-height:33px;padding:4px 3px;min-width:0}.pred-rank{flex:none;background:#e73349;color:white;font-size:10px;font-weight:800;border-radius:50%;width:17px;height:17px;display:grid;place-items:center}.pred-panel-pair .pred-rank{background:#158dc8}.pred-boats{display:flex;align-items:center;gap:1px;white-space:nowrap;min-width:0}.pred-boat{width:17px;height:19px;flex:none;display:grid;place-items:center;border-radius:4px;font-size:12px;font-weight:800;color:white}.pred-boat-1{background:#f8f8f8;color:#151515;border:1px solid #cfd5de}.pred-boat-2{background:#17191c}.pred-boat-3{background:#ed3348}.pred-boat-4{background:#2789e8}.pred-boat-5{background:#f7c626;color:#161616}.pred-boat-6{background:#2cbb61}.pred-dash{font-size:10px;color:#617083}.pred-odds{font-size:10px;color:#e23c50;margin-left:auto;white-space:nowrap}.pred-panel-pair .pred-odds{color:#168acb}.pred-group{margin:8px 0 11px}.pred-group h3{font-size:11px;padding:5px 6px;border-radius:6px;margin:0 0 5px}.pred-group-safe{background:#e4f4fd;color:#1281c5}.pred-group-return{background:#e9f8ed;color:#239c56}.pred-group-long{background:#fff0f0;color:#d64050}.pred-group .pred-bet{margin-bottom:5px}.pred-comment{border-top:1px solid #e3e8ef;margin-top:11px;padding-top:10px}.pred-comment b{font-size:11px;color:#e34356}.pred-panel-pair .pred-comment b{color:#208ac5}.pred-comment p{font-size:10px;color:#586577;line-height:1.6;margin:5px 0 0;overflow-wrap:anywhere}.pred-footer-note{background:#fff3f4;color:#ad5963;border:1px solid #f3d8dd;border-radius:12px;padding:12px;margin:14px 0 20px;font-size:11px;line-height:1.7}@media(min-width:650px){.pred-layout{gap:16px}.pred-panel{padding:16px}.pred-bet{min-height:40px;padding:7px}.pred-boat{width:23px;height:24px}.pred-odds{font-size:13px}.pred-comment p{font-size:12px}}@media(max-width:360px){.pred-layout{gap:5px}.pred-panel{padding:8px 4px}.pred-boat{width:15px;height:18px;font-size:11px}.pred-rank{width:15px;height:15px;font-size:9px}.pred-odds{font-size:9px}}

/* v0.19.47: dual trifecta prediction cards */
.pred-panel-hole{border-color:#cfe0f5}
.pred-panel-hole h2 small{color:#168acb}
.pred-panel-sub{display:flex;flex-wrap:wrap;gap:4px;min-height:0;margin:7px 0 12px}
.pred-key{font-size:9px;font-weight:700;border-radius:4px;padding:3px 4px}
.pred-key-red{color:#c9344a;background:#fff0f2}.pred-key-blue{color:#177cc7;background:#eaf5ff}
.pred-expanded .pred-rank{background:#168bd0}.pred-panel-hole .pred-selected .pred-rank{background:#e73349}
.pred-bet{align-items:flex-start;min-height:55px;padding:5px 3px}
.pred-bet-main{display:flex;flex:1;min-width:0;flex-direction:column;gap:5px}
.pred-stake{font-size:9px;color:#566779;white-space:nowrap}
.pred-bet-right{display:flex;flex-direction:column;align-items:flex-end;gap:3px;margin-left:auto;min-width:0}
.pred-estimate{font-size:8px;line-height:1.3;text-align:right;color:#738398;white-space:nowrap}
.pred-estimate strong{font-size:10px;color:#263e55}
.pred-panel-total{display:flex;justify-content:space-between;gap:4px;border-top:1px solid #e2e8f0;padding-top:9px;margin-top:10px;font-size:10px}
.pred-panel-total strong{font-size:12px}.pred-panel-note{font-size:9px;color:#728198;line-height:1.5;margin-top:8px}
@media(max-width:400px){.pred-panel{padding:8px 4px}.pred-boat{width:15px;height:18px;font-size:11px}.pred-rank{width:16px;height:16px;font-size:9px}.pred-stake{font-size:8px}.pred-estimate{font-size:7px}.pred-estimate strong{font-size:9px}.pred-panel h2{font-size:15px}.pred-panel h2 small{font-size:9px}}

/* v0.19.48: separate five- and ten-ticket estimated payout summaries */
.pred-odds-status{font-size:10px;color:#46728f;text-align:right;margin:0 3px 8px}
.pred-summary{border-top:1px solid #dce5ef;margin-top:10px;padding-top:9px;display:grid;gap:8px}
.pred-summary>div{display:flex;flex-direction:column;gap:3px;background:#f3f7fc;border-radius:7px;padding:7px 5px}
.pred-summary span{font-size:9px;color:#516b84;font-weight:700}
.pred-summary strong{font-size:14px;color:#174f88;text-align:right}
.pred-summary small{font-size:8px;color:#6c8095;line-height:1.5}

/* v0.19.53: staged prediction preparation indicator */
#predictionBody:has(.pred-loading){background:transparent;border:0;box-shadow:none;padding:0;margin-top:28px}
.pred-loading{max-width:480px;margin:32px auto;padding:35px 22px;text-align:center;background:white;border:1px solid #dce8f7;border-radius:22px;box-shadow:0 10px 35px #123c6a10}
.pred-loading-symbol{width:60px;height:60px;margin:0 auto 15px;display:grid;place-items:center;border-radius:50%;background:linear-gradient(135deg,#0b68c7,#51b4f7);color:white;font-size:29px;animation:pred-pulse 1.8s ease-in-out infinite}
.pred-loading h2{margin:0 0 10px;color:#173a66;font-size:22px}.pred-loading-stage{margin:0 0 20px;color:#49759e;font-size:13px;font-weight:700}
.pred-loading-track{height:11px;background:#e5effa;border-radius:20px;overflow:hidden}.pred-loading-fill{height:100%;border-radius:20px;background:linear-gradient(90deg,#0b71d7,#56c2f3);transition:width .5s ease;position:relative}.pred-loading-fill:after{content:'';position:absolute;inset:0;background:linear-gradient(90deg,transparent,#ffffff70,transparent);animation:pred-shimmer 1.5s linear infinite}
.pred-loading-meta{display:flex;justify-content:space-between;gap:10px;margin-top:12px;font-size:11px;color:#6a87a7}.pred-loading-hint{font-size:11px!important;color:#8497aa!important;margin-top:18px!important}
@keyframes pred-pulse{50%{transform:scale(1.06);box-shadow:0 0 0 9px #0b71d71a}}@keyframes pred-shimmer{to{transform:translateX(100%)}}
@media(max-width:390px){.pred-loading{margin:20px 10px;padding:26px 16px}.pred-loading-meta{font-size:10px}}

/* v0.19.54: bar represents only completed stages; never an estimated percentage */
.pred-loading-fill{transition:width .25s ease}
.pred-loading-steps{font-weight:700;color:#285e99}

/* v0.19.55: truthful indeterminate loading, gold suichi ticket */
.pred-loading-track{position:relative}
.pred-loading-fill.pred-loading-indeterminate{width:35%!important;transition:none;animation:pred-wait-slide 1.35s ease-in-out infinite alternate}
@keyframes pred-wait-slide{from{transform:translateX(0)}to{transform:translateX(185%)}}
.pred-bet.pred-suichi{background:linear-gradient(130deg,#fff8dc,#fff0b5 65%,#fff9e6);border:2px solid #d6a11e;box-shadow:0 0 0 1px #f9e6a0,0 2px 10px #b8860b38}
.pred-suichi-label{display:inline-flex;align-self:flex-start;color:#835500;background:#ffe18a;border:1px solid #d6a11e;border-radius:4px;font-weight:900;font-size:9px;padding:1px 4px;white-space:nowrap}

/* v0.19.57: dual-plan allocation and suichi legend */
.pred-key-gold{background:#fff2c9;color:#805500;border:1px solid #d9ad45}.pred-panel-sub{display:flex;flex-wrap:wrap;gap:5px}.pred-bet .pred-stake{display:block;white-space:nowrap;font-size:clamp(9px,1.6vw,12px)}.pred-bet .pred-estimate{line-height:1.5;font-size:clamp(9px,1.5vw,12px)}.pred-bet .pred-estimate strong{font-size:inherit}.pred-bet-main{min-width:0}.pred-bet-right{min-width:0}.pred-panel-total{line-height:1.7}

/* v0.19.58: category-matched ticket colors, with gold priority for suichi */
.pred-bet.pred-selected:not(.pred-suichi){background:#fff0f2;border:1px solid #efbac3;border-left:3px solid #e73349}
.pred-bet.pred-expanded:not(.pred-suichi){background:#eaf4ff;border:1px solid #b9d9f8;border-left:3px solid #168bd3}
.pred-bet.pred-suichi{background:linear-gradient(130deg,#fff8dc,#fff0b5 65%,#fff9e6);border:2px solid #d6a11e;box-shadow:0 0 0 1px #f9e6a0,0 2px 10px #b8860b38}
.pred-panel-sub .pred-key{white-space:nowrap}

/* v0.19.59: wave race loading, boat advances in ~8 seconds and waits for actual completion */
.pred-race-track{display:flex;align-items:center;gap:3px;width:100%;height:88px;margin:4px 0 0;overflow:visible}
.pred-turn{width:24px;flex:0 0 24px;height:52px;display:flex;align-items:center;justify-content:center;filter:drop-shadow(0 2px 2px #47799b44)}
.pred-turn svg{width:22px;height:42px}
.pred-wave{position:relative;flex:1;min-width:0;height:38px;border-radius:22px;background:repeating-linear-gradient(170deg,#d9f4ff 0px,#d9f4ff 11px,#b8e9fa 12px,#e5f8ff 22px);box-shadow:inset 0 2px 7px #83c5e555;overflow:visible}
.pred-wave:before,.pred-wave:after{content:'';position:absolute;left:0;right:0;height:9px;background:radial-gradient(ellipse 13px 7px at 13px 7px,#fff9 65%,transparent 72%) repeat-x;background-size:26px 9px;pointer-events:none}
.pred-wave:before{top:0}.pred-wave:after{bottom:0;transform:rotate(180deg)}
.pred-wave-water{position:absolute;left:0;top:0;bottom:0;width:0;background:linear-gradient(90deg,#5bc7ef88,#1593e788);border-radius:22px;transition:width .09s linear}
.pred-loader-boat{position:absolute;z-index:2;top:-22px;width:44px;height:55px;left:0;transition:left .09s linear;filter:drop-shadow(0 4px 3px #145b9866)}
.pred-loader-boat svg{width:55px;height:55px;transform:rotate(5deg)}
.pred-loading-track-hidden{position:absolute!important;width:1px!important;height:1px!important;opacity:0!important;overflow:hidden!important;pointer-events:none!important}
@media(max-width:390px){.pred-race-track{height:78px}.pred-turn{width:19px;flex-basis:19px}.pred-loader-boat svg{width:47px}}

/* v0.19.60: clock and isolated race animation; protect ticket lane numbers */
.pred-grand-clock{width:116px;height:116px;margin:0 auto 16px;filter:drop-shadow(0 3px 7px #1a639126)}
.pred-grand-clock svg{width:100%;height:100%;display:block}
.pred-clock-hand{transform-origin:60px 60px;transition:transform .09s linear}
.pred-boats .pred-boat{position:static!important;z-index:auto!important;top:auto!important;left:auto!important;transform:none!important;filter:none!important;transition:none!important;width:17px!important;height:19px!important;flex:0 0 17px!important;display:grid!important;place-items:center!important;border-radius:4px!important;font-size:12px!important}
#prediction{overflow:hidden;isolation:isolate}
#legacy{display:none!important;visibility:hidden!important}
@media(min-width:650px){.pred-boats .pred-boat{width:23px!important;height:24px!important;flex-basis:23px!important}}

/* v0.19.61: uniform ticket borders, hit badge; payout estimates remain only in summary */
.pred-bet.pred-selected:not(.pred-suichi){border:1px solid #efbac3}
.pred-bet.pred-expanded:not(.pred-suichi){border:1px solid #b9d9f8}
.pred-bet.pred-suichi{border:2px solid #d6a11e}
.pred-hit{display:inline-flex;align-items:center;justify-content:center;font-size:clamp(12px,2.2vw,18px);line-height:1;flex:none;margin-left:2px}

/* v0.19.62: compact side-by-side stake plans and confirmed prediction results */
.pred-stakes-row{display:flex;align-items:center;gap:5px;flex-wrap:wrap;min-width:0}
.pred-bet .pred-stakes-row .pred-stake{display:inline-block;font-size:clamp(8px,1.25vw,11px);white-space:nowrap}
.pred-result-panel{margin-top:12px;padding:10px 8px;border:1px solid #d7e2f0;border-radius:10px;background:#f6f9fd}
.pred-result-panel h3{font-size:clamp(12px,1.7vw,16px);margin:0 0 8px;color:#173b64;display:flex;align-items:center;gap:7px;flex-wrap:wrap}
.pred-result-panel p{font-size:11px;color:#64748b;margin:0}
.pred-result-ticket{display:flex;justify-content:space-between;align-items:center;gap:5px;font-size:clamp(10px,1.6vw,13px)}
.pred-result-ticket>span{display:flex;align-items:center;gap:2px}
.pred-result-ticket strong{white-space:nowrap;color:#e2364d}
.pred-result-won{border-color:#dfb34a;background:#fff9e9}
.pred-result-lost{border-color:#e3bac2;background:#fff4f5}
.pred-result-hit{color:#b07a0d;font-weight:800}
.pred-result-miss{color:#c7364c;font-weight:800}
.pred-result-details{margin-top:9px;display:grid;gap:7px}
.pred-result-details>div{display:grid;grid-template-columns:minmax(0,1fr) auto;gap:3px 6px;border-top:1px solid #e4d9bd;padding-top:7px;font-size:clamp(9px,1.3vw,12px)}
.pred-result-details span{color:#64748b}
.pred-result-details strong{text-align:right;color:#203e61}

/* v0.19.63: compact aligned totals and stake labels */
.pred-panel-total{display:flex;align-items:center;justify-content:space-between;gap:6px;line-height:1.3;font-size:clamp(10px,1.8vw,13px);white-space:nowrap}
.pred-panel-total strong{font-size:clamp(12px,2.3vw,16px);white-space:nowrap}
.pred-bet .pred-stakes-row{display:flex;flex-wrap:wrap;gap:2px 6px;align-items:center}
.pred-bet .pred-stakes-row .pred-stake{font-size:clamp(7px,1.12vw,10px);white-space:nowrap;letter-spacing:-.03em}
.pred-result-details span{overflow-wrap:anywhere}

/* v0.19.64: prediction commentary and legible stake labels */
.pred-reason{margin:0 0 12px;padding:10px 9px;background:#f5f8fd;border:1px solid #dce8f5;border-radius:10px;min-width:0}
.pred-reason h3{font-size:13px;font-weight:800;color:#244c76;margin:0 0 7px}
.pred-reason p{font-size:clamp(10px,1.65vw,13px);line-height:1.75;color:#3c526b;margin:0;overflow-wrap:anywhere}
.pred-reason strong{color:#1b426f}
.pred-panel-hole .pred-reason{background:#f1f8ff;border-color:#d0e4f8}
.pred-bet .pred-stakes-row .pred-stake{font-size:clamp(9px,1.55vw,12px);letter-spacing:-.025em;white-space:normal;line-height:1.45}
.pred-bet .pred-stakes-row{gap:3px 8px}
@media(max-width:400px){.pred-bet .pred-stakes-row .pred-stake{font-size:9px}}

/* v0.19.65: separator between reasoning and ticket list */
.pred-reason{margin-bottom:10px}
.pred-reason + .pred-bets{border-top:1px solid #d6e0ec;padding-top:12px}
