:root{
  --bg-url: url('https://images.unsplash.com/photo-1503264116251-35a269479413?q=80&w=1920&auto=format&fit=crop&ixlib=rb-4.0.3&s=000000');
  --overlay: rgba(0,0,0,0.35);
  --accent: rgba(26,115,232,0.5);
  --glass: rgba(255,255,255,0.425);
}

html,
body{
  height:100%;
  margin:0;
  font-family:Inter,system-ui,-apple-system,"Segoe UI",Roboto,"Hiragino Kaku Gothic ProN","Noto Sans JP",sans-serif;
}

body{
  background-image:var(--bg-url);
  background-size:cover;
  background-position:center;
  background-repeat:no-repeat;
  transition:background-image .35s ease;
  display:flex;
  align-items:center;
  justify-content:center;
  color:#111;
}

/* 追加：動画レイヤー */
#bgMedia{
  position:fixed;
  inset:0;
  z-index:0;
  overflow:hidden;
}

#bgMedia video,
#bgMedia iframe{
  width:100%;
  height:100%;
  object-fit:cover;
  border:none;
  pointer-events:none;
}

.overlay{
  position:fixed;
  inset:0;
  background:var(--overlay);
  pointer-events:none;
}

.container{
  position:relative;
  z-index:2;
  width:100%;
  max-width:860px;
  padding:48px 24px;
  box-sizing:border-box;
  display:flex;
  flex-direction:column;
  align-items:center;
}

.search-box{
  width:84.55%;
  display:flex;
  align-items:center;
  background:rgba(255,255,255,0.475);
  border-radius:28px;
  padding:5.6px 8.4px;
  box-shadow:0 6px 18px rgba(0,0,0,0.16);
}

.search-input{
  flex:1;
  border:0;
  background:transparent;
  padding:9.8px 8.4px;
  font-size:18px;
  outline:none;
  border-radius:20px;
}

.btn{
  background:var(--accent);
  color:#fff;
  border:0;
  padding:7px 9.8px;
  border-radius:20px;
  cursor:pointer;
  margin-left:8px;
  display:inline-flex;
  align-items:center;
  gap:8px;
  font-weight:600;
}

.btn.secondary{
  background:transparent;
  color:white;
  border:1px solid rgba(255,255,255,0.18);
  padding:8px 12px;
  border-radius:14px;
  margin-left:10px;
}

.controls{
  margin-top:18px;
  display:flex;
  gap:10px;
  align-items:center;
}

.muted{
  color:rgba(255,255,255,0.85);
  font-size:14px;
  margin-top:10px;
}

.bg-controls{
  position:fixed;
  right:18px;
  bottom:18px;
  z-index:3;
  display:flex;
  gap:8px;
  align-items:center;
  background:rgba(0,0,0,0.45);
  padding:8px;
  border-radius:10px;
}

.bg-controls button{
  background:transparent;
  border:1px solid rgba(255,255,255,0.18);
  color:#fff;
  padding:6px 8px;
  border-radius:8px;
  cursor:pointer;
}

.url-prompt{
  position:fixed;
  right:18px;
  bottom:76px;
  z-index:4;
  display:none;
  flex-direction:column;
  gap:6px;
  background:rgba(0,0,0,0.6);
  padding:10px;
  border-radius:10px;
}

.url-prompt input{
  width:320px;
  max-width:calc(100vw - 56px);
  padding:8px;
  border-radius:6px;
  border:1px solid rgba(255,255,255,0.12);
  background:rgba(255,255,255,0.06);
  color:#fff;
  outline:none;
}

.small{
  font-size:12px;
  color:rgba(255,255,255,0.85);
}

.attribution{
  margin-top:18px;
  color:rgba(255,255,255,0.9);
  font-size:13px;
}

@media (max-width:520px){
  .logo{
    font-size:36px;
  }

  .search-input{
    font-size:16px;
  }

  .bg-controls{
    right:10px;
    bottom:12px;
  }
}