.identity span { font-size: 20px; }
#panel { top: 0; left: 50%; right: auto; width: min(880px, 94%); max-height: calc(100% - 82px); transform: translateX(-50%); border-radius: 0 0 28px 28px; padding: 48px; background: #eaf0f7f5; color: #18375c; border: 1px solid #fff9; border-top: 0; box-shadow: 0 24px 80px #061c4d66; animation: panel-down .5s cubic-bezier(.22,1,.36,1); overscroll-behavior: contain; }
#panel[hidden] { display: none; }
#panel.is-closing { animation: panel-up .28s ease-in forwards; }
#panel h2 { font-size: clamp(32px, 3.4vw, 52px); margin: 12px 0 20px; letter-spacing: -.025em; }
#panel p, #panel a { color: inherit; }
#panel p { opacity: .8; margin: 0 0 24px; }
#panel .eyebrow { color: #315d91; opacity: 1; letter-spacing: .14em; }
#close { position: absolute; z-index: 5; top: 16px; right: 16px; width: 40px; height: 40px; padding: 0; border: 1px solid #18375c33; border-radius: 50%; font-size: 0; line-height: 1; color: #18375c; background: #eaf0f7; box-shadow: 0 2px 8px #18375c12; }
#close::before, #close::after { content: ''; position: absolute; top: 50%; left: 50%; width: 16px; height: 1.5px; border-radius: 1px; background: currentColor; transform: translate(-50%, -50%) rotate(45deg); }
#close::after { transform: translate(-50%, -50%) rotate(-45deg); }
#close:hover { color: #226ee2; background: #fff; }
.contact-layout { display: grid; grid-template-columns: 1.15fr 1fr; gap: 48px; align-items: end; }
#panel .contact-email { display: flex; justify-content: space-between; gap: 12px; padding: 18px 0; border-top: 1px solid #18375c33; border-bottom: 1px solid #18375c33; font-size: 14px; font-weight: 500; text-decoration: none; overflow-wrap: anywhere; }
.contact-socials { display: grid; grid-template-columns: 1fr 1fr; gap: 0 24px; margin-top: 14px; }
#panel .contact-socials a { display: flex; justify-content: space-between; padding: 14px 0; text-decoration: none; }
#panel a:hover { color: #226ee2; }
.contact-note { display: block; margin-top: 32px; font-size: 10px; line-height: 16px; letter-spacing: .1em; opacity: .6; }
#panel.project-panel { position: fixed; top: 50%; left: 50%; width: min(1050px, calc(100vw - 48px)); max-height: calc(100svh - 64px); transform: translate(-50%, -50%); border: 1px solid #fff9; border-radius: 28px; overflow-y: auto; animation: project-in .3s ease-out; }
#panel.project-panel.is-closing { animation: project-out .42s cubic-bezier(.4,0,.2,1) forwards; }
@keyframes project-in { from { opacity: 0; transform: translate(-50%, calc(-50% + 32px)) scale(.975); } to { opacity: 1; transform: translate(-50%, -50%) scale(1); } }
@keyframes project-out { from { opacity: 1; transform: translate(-50%, -50%) scale(1); } to { opacity: 0; transform: translate(-50%, calc(-50% + 20px)) scale(.985); } }
.project-meta { display: flex; flex-wrap: wrap; gap: 12px 32px; padding: 20px 0; border-block: 1px solid #18375c26; margin: 24px 0; font-size: 14px; line-height: 19.6px; }
.project-meta span { display: grid; gap: 4px; }
.project-meta b { font-weight: 500; }
.project-actions { display: flex; flex-wrap: wrap; gap: 10px; margin: 20px 0 28px; }
#panel .project-actions a { display: inline-flex; padding: 12px 18px; border: 1px solid #18375c44; border-radius: 30px; text-decoration: none; background: #FFFFFF; font-size: 14px; font-weight: 500; line-height: 19.6px; }
.project-body h3 { font-size: 22px; font-weight: 500; line-height: 1.3; margin: 40px 0 16px; }
.project-media { display: block; width: 100%; height: auto; border-radius: 12px; margin: 24px 0; background: #d6dfe9; }
.project-body ul { padding-left: 22px; font-size: 18px; line-height: 1.6; }
.detail-link { padding: 12px 18px; border: 1px solid #18375c44; border-radius: 30px; font-size: 14px; font-weight: 500; line-height: 19.6px; margin: 0 0 20px; background: #FFFFFF; }
.mobile-card strong { font-size: 16px; line-height: 22.4px; font-weight: 500; }
.mobile-card video { width: 100%; height: 100%; object-fit: cover; display: block; }
@keyframes panel-down { from { transform: translate(-50%, -100%); opacity: .3; } to { transform: translate(-50%, 0); opacity: 1; } }
@keyframes panel-up { to { transform: translate(-50%, -100%); opacity: 0; } }
@media(max-width:700px) { .identity span { font-size: 20px; } .screen footer nav button { font-size: 10px; line-height: 16px; } #panel { padding: 48px 24px 28px; width: 96%; max-height: calc(100% - 70px); border-radius: 0 0 22px 22px; } .contact-layout { grid-template-columns: 1fr; gap: 12px; } #panel h2 { font-size: 36px; } .contact-note { margin-top: 20px; } }
@media(prefers-reduced-motion:reduce) { #panel, #panel.is-closing { animation: none; } }
@media(max-width:700px) { #panel.project-panel { width: calc(100vw - 32px); max-height: calc(100svh - 40px); border-radius: 22px; } }
@media(prefers-reduced-motion:reduce) { #panel.project-panel, #panel.project-panel.is-closing { animation: none; } }
/* Only the content scrolls, keeping the close control anchored to the dialog. */
#panel.project-panel { background: #EAF0F7; padding: 0; overflow: hidden; animation-duration: .65s; animation-timing-function: cubic-bezier(.16,1,.3,1); backdrop-filter: none; }
#panel.project-panel #close { background: #FFFFFF; }
#panel.project-panel #panel-content { background: #EAF0F7; max-height: calc(100svh - 64px); overflow-y: auto; overscroll-behavior: contain; padding: 64px 48px 48px; scrollbar-width: none; -ms-overflow-style: none; }
#panel.project-panel #panel-content::-webkit-scrollbar { display: none; width: 0; height: 0; }
@media(max-width:700px) { #panel.project-panel #panel-content { background: #EAF0F7; max-height: calc(100svh - 40px); padding: 64px 24px 28px; } }
/* Card-to-dialog motion is driven by the clicked card's actual bounds. */
#panel.project-panel, #panel.project-panel.is-closing { animation: none; transform-origin: center; }

.project-transition { position: fixed; z-index: 10000; left: 50%; top: 50%; pointer-events: none; overflow: hidden; transform-origin: center; will-change: transform, clip-path, opacity; }
.project-transition canvas { display: block; width: 100%; height: 100%; }
/* Detail titles use the same weight and readable word spacing at every width. */
#panel.project-panel #panel-content > h2 {
 font-weight: 600;
 letter-spacing: 0;
 word-spacing: .08em;
}

#panel .project-body .project-highlights { margin: 0 0 24px; padding-left: 22px; font-size: 18px; line-height: 25.2px; opacity: .8; }
#panel .project-body .project-highlights li + li { margin-top: 8px; }
/* Each Onanmedia card keeps its description, image and destination together. */
.project-cards { display: grid; gap: 32px; }
.project-card { min-width: 0; padding-top: 8px; border-top: 1px solid #18375c26; }
.project-card:first-child { border-top: 0; }
.project-card h3 { margin-top: 24px; }
.project-card .project-actions { margin-bottom: 0; }
.project-card .detail-link { margin-bottom: 0; }
.project-body h4 { font-size: 18px; font-weight: 500; line-height: 25.2px; margin: 28px 0 12px; }
