/*
Theme Name: Arthur Lee — Old Site Replica
Theme URI: https://arthurleeactor.com/
Author: Arthur Lee / OpenAI
Description: A clean self-hosted WordPress replica of the current Arthur Lee actor website, with editable media placeholders.
Version: 2.1.0
Text Domain: arthur-lee-old-replica
*/

:root{
  --page-bg:#fff;
  --text:#222;
  --muted:#777;
  --border:#e8e8e8;
  --content:1000px;
  /* Header spacing controls — adjust these in Additional CSS if desired. */
  --header-top-space:34px;
  --header-bottom-space:26px;
  --title-menu-gap:22px;
  --side:32px;
}

*{box-sizing:border-box}
html{margin:0!important;padding:0}
body{
  margin:0;
  background:var(--page-bg);
  color:var(--text);
  font-family:Arial, Helvetica, sans-serif;
  font-size:16px;
  line-height:1.55;
}
a{color:inherit}
img{max-width:100%;height:auto;display:block}
.site-header{
  position:sticky;
  top:0;
  left:0;
  right:0;
  width:100%;
  z-index:1000;
  padding:var(--header-top-space) var(--side) var(--header-bottom-space);
  text-align:center;
  background:#fff;
}
.site-title{
  display:block;
  margin:0 0 var(--title-menu-gap);
  text-decoration:none;
  font-size:30px;
  line-height:1;
  font-weight:400;
  letter-spacing:.16em;
}
.site-nav ul{
  display:flex;
  flex-wrap:wrap;
  justify-content:center;
  align-items:center;
  gap:8px 30px;
  list-style:none;
  margin:0;
  padding:0;
}
.site-nav a{
  text-decoration:none;
  font-size:14px;
  line-height:1.2;
}
.site-nav a:hover,
.site-nav .current-menu-item > a{opacity:.55}

.site-main{
  width:min(var(--content), calc(100% - (var(--side) * 2)));
  margin:0 auto;
  padding:18px 0 70px;
}
.home-main{padding-top:8px}
.page-main{padding-top:36px}

.page-content,
.media-page-content{
  width:100%;
}
.page-content > *:first-child,
.media-page-content > *:first-child{margin-top:0}

/* Keep every page element inside the same maximum width as the homepage image.
   This also prevents WordPress wide/full-width blocks and audio players from
   becoming wider than the headshot on large screens. */
.site-main .alignwide,
.site-main .alignfull{
  width:100% !important;
  max-width:100% !important;
  margin-left:0 !important;
  margin-right:0 !important;
}
.site-main audio,
.site-main .wp-block-audio,
.site-main .wp-block-audio audio{
  width:100% !important;
  max-width:100% !important;
}

.home-image{
  width:100%;
  margin:0 auto;
}
.home-image img{
  width:100%;
  height:auto;
}

.screen-page,
.games-page,
.voice-page,
.korean-page,
.contact-page,
.stage-page{
  padding-top:18px;
}
.replica-section{
  margin:0 0 58px;
}
.replica-section:last-child{margin-bottom:0}
.replica-heading{
  margin:0 0 18px;
  text-align:center;
  font-size:18px;
  line-height:1.3;
  font-weight:400;
}
.replica-video{
  width:100%;
  max-width:1000px;
  margin:0 auto 20px;
}
.replica-video video,
.wp-block-video video{
  width:100%;
  height:auto;
  display:block;
}
.placeholder{
  width:100%;
  min-height:360px;
  border:1px dashed #cfcfcf;
  background:#fafafa;
  display:flex;
  align-items:center;
  justify-content:center;
  text-align:center;
  padding:40px;
  color:#777;
}
.placeholder.small{min-height:180px}
.placeholder strong{display:block;color:#333;font-weight:400;margin-bottom:7px}
.placeholder span{display:block;font-size:13px}

.gallery-grid{
  display:grid;
  grid-template-columns:repeat(3,minmax(0,1fr));
  gap:22px;
}
.gallery-item img{width:100%}

.voice-list{
  max-width:760px;
  margin:0 auto;
}
.voice-item{
  margin:0 0 28px;
}
.voice-item h2{
  margin:0 0 8px;
  font-size:16px;
  font-weight:400;
}
.audio-placeholder{
  border:1px dashed #cfcfcf;
  background:#fafafa;
  min-height:86px;
  display:flex;
  align-items:center;
  justify-content:center;
  color:#777;
  text-align:center;
  padding:20px;
}

.contact-content{
  max-width:680px;
  margin:20px auto 0;
  text-align:center;
}
.contact-content h1{
  font-size:18px;
  font-weight:400;
  margin:0 0 25px;
}
.contact-content p{margin:0 0 7px}
.contact-content .agency{margin-bottom:24px}
.contact-content a{text-decoration:none}

.korean-content{text-align:center}
.korean-content img{margin:0 auto}
.korean-content .wp-block-video{max-width:1000px;margin-left:auto;margin-right:auto}

.site-footer{
  width:min(var(--content), calc(100% - (var(--side) * 2)));
  margin:0 auto;
  padding:25px 0 45px;
  border-top:1px solid var(--border);
  color:var(--muted);
  text-align:center;
  font-size:12px;
}
.site-footer a{text-decoration:none}

.wp-block-image{margin-left:auto;margin-right:auto}
.wp-block-gallery{margin-left:auto;margin-right:auto}
.wp-block-audio{margin-left:auto;margin-right:auto}

/* Sticky header naturally stays in document flow, so page content cannot slide underneath it. */
body.admin-bar .site-header{top:32px}
@media (max-width:782px){
  body.admin-bar .site-header{top:46px}
}

@media (max-width:700px){
   :root{--side:18px}
  .site-header{padding-top:24px;padding-bottom:22px}
  .site-title{font-size:25px;margin-bottom:18px}
  .site-nav ul{gap:12px 18px}
  .site-nav a{font-size:13px}
  .site-main{padding-bottom:45px}
  .gallery-grid{grid-template-columns:1fr 1fr;gap:12px}
  .replica-section{margin-bottom:42px}
}
@media (max-width:460px){
  :root{}
  .gallery-grid{grid-template-columns:1fr}
}


/* Games page carousel */
.games-carousel-wrap{
  position:relative;
  width:100%;
  max-width:1000px;
  margin:26px auto 0;
  padding:0 52px 42px;
}
.games-carousel-viewport{overflow:hidden;width:100%}
.games-carousel-track{
  display:flex!important;
  flex-wrap:nowrap!important;
  gap:10px!important;
  margin:0!important;
  padding:0!important;
  list-style:none!important;
  transform:translateX(0);
  transition:transform .35s ease;
  will-change:transform;
}
.games-carousel-track > li,
.games-carousel-track > .games-carousel-slide{
  flex:0 0 calc((100% - 30px) / 4)!important;
  width:calc((100% - 30px) / 4)!important;
  margin:0!important;
  padding:0!important;
  min-width:0!important;
  list-style:none!important;
}
.games-carousel-track img{
  display:block!important;
  width:100%!important;
  height:auto!important;
  aspect-ratio:1/1!important;
  object-fit:cover!important;
}
.games-carousel-button{
  position:absolute;
  top:50%;
  transform:translateY(-50%);
  width:38px;
  height:38px;
  border:0;
  border-radius:50%;
  background:#ddd;
  color:#222;
  font-size:25px;
  line-height:38px;
  text-align:center;
  cursor:pointer;
  padding:0;
  z-index:2;
}
.games-carousel-button:hover{background:#cfcfcf}
.games-carousel-prev{left:4px}
.games-carousel-next{right:4px}
.games-carousel-dots{
  position:absolute;
  left:0;
  right:0;
  bottom:0;
  display:flex;
  justify-content:center;
  gap:10px;
}
.games-carousel-dot{
  width:9px;
  height:9px;
  border-radius:50%;
  border:0;
  padding:0;
  background:#cfcfcf;
  cursor:pointer;
}
.games-carousel-dot.is-active{background:#222}
.games-carousel-placeholder{
  width:100%;
  aspect-ratio:1/1;
  min-height:0;
  padding:20px;
  border:1px dashed #cfcfcf;
  background:#fafafa;
}
@media (max-width:700px){
  .games-carousel-wrap{padding-left:42px;padding-right:42px}
  .games-carousel-track > li,
  .games-carousel-track > .games-carousel-slide{
    flex-basis:calc((100% - 10px) / 2)!important;
    width:calc((100% - 10px) / 2)!important;
  }
}
@media (max-width:460px){
  .games-carousel-wrap{padding-left:38px;padding-right:38px}
  .games-carousel-track > li,
  .games-carousel-track > .games-carousel-slide{
    flex-basis:100%!important;
    width:100%!important;
  }
}

/* Games carousel — preserve full image in the lightbox */
.games-carousel-track > li,
.games-carousel-track > .games-carousel-slide{
  overflow:hidden;
}
.games-carousel-track img{
  object-fit:cover!important;
  object-position:50% 50%;
}
.games-carousel-track img[data-crop-position]{
  object-position:var(--games-crop-position, 50% 50%)!important;
}
.games-lightbox-open{overflow:hidden}
.games-lightbox{
  position:fixed;
  inset:0;
  z-index:99999;
  background:rgba(0,0,0,.88);
  display:flex;
  align-items:center;
  justify-content:center;
  padding:40px;
}
.games-lightbox-figure{
  margin:0;
  max-width:95vw;
  max-height:92vh;
  display:flex;
  align-items:center;
  justify-content:center;
}
.games-lightbox-image{
  display:block;
  max-width:95vw;
  max-height:92vh;
  width:auto;
  height:auto;
  object-fit:contain;
}
.games-lightbox-close{
  position:fixed;
  top:18px;
  right:24px;
  width:44px;
  height:44px;
  border:0;
  background:rgba(255,255,255,.12);
  color:#fff;
  border-radius:50%;
  font-size:30px;
  line-height:40px;
  cursor:pointer;
  z-index:100000;
}
.games-lightbox-close:hover{background:rgba(255,255,255,.22)}
@media (max-width:700px){
  .games-lightbox{padding:18px}
  .games-lightbox-image{max-width:96vw;max-height:88vh}
}


/* Desktop header sizing; mobile retains the smaller responsive header. */
@media (min-width:701px){
  .site-title{font-size:37.5px}
  .site-nav a{font-size:17.5px}
  .page-main{padding-top:70px}
}
@media (max-width:700px){
  .site-title{font-size:25px!important}
  .site-nav a{font-size:14.3px!important}
}

/* Prevent audio players and other page content from exceeding the homepage headshot width. */
.site-main,
.site-footer{max-width:var(--content)!important}
.site-main .wp-block-audio,
.site-main .wp-block-audio audio,
.site-main audio,
.site-main iframe,
.site-main .wp-block-embed,
.site-main .wp-block-video,
.site-main .wp-block-image,
.site-main .wp-block-gallery{
  max-width:100%!important;
}


/* Self-hosted video layout — v1.7 */
.screen-video-large-wrap{width:100%;margin:0 0 26px}
.screen-video-row{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:22px}
.screen-video-small{min-width:0}
.screen-video-label,.games-video-label{text-align:center;font-size:16px;line-height:1.35;margin-top:8px}
.arthur-local-video.replica-video{margin:0}
.arthur-local-video.replica-video video{width:100%;height:auto;display:block;background:#000}
.games-video-wrap{width:100%;margin:0 0 30px}
.games-video-wrap .replica-video{max-width:1000px;margin:0 auto}
.korean-video-wrap{width:100%;max-width:1000px;margin:0 auto 30px}
.korean-video-wrap .replica-video{margin:0}
@media (max-width:700px){
  .screen-video-row{grid-template-columns:1fr;gap:28px}
}


/* Korean flag — make it 100% larger than the current v1.9 size */
.site-header .menu-item:last-child img,
.site-header .menu-item:last-child a img,
.site-header nav .menu-item:last-child img,
.site-header nav .menu-item:last-child a img,
header .menu-item:last-child img,
header .menu-item:last-child a img {
    width: 2em !important;
    height: auto !important;
    max-width: none !important;
}
