/* =============================================
   CSS VARIABLES & RESET
============================================= */
:root {
  --pink: #ff6eb4;
  --pink-dim: rgba(255, 110, 180, 0.15);
  --pink-glow: rgba(255, 110, 180, 0.4);
  --lavender: #c084fc;
  --bg: #0d0a12;
  --bg2: #150f1e;
  --text: #f0e8f5;
  --text-dim: #9988aa;
  --blue: #a78bfa;
  --font-pixel: 'Press Start 2P', cursive;
  --font-mono: 'Space Mono', monospace;
  --font-body: 'Noto Sans JP', sans-serif;
}

*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

html, body {
  width: 100%; overflow-x: hidden;
  background: var(--bg);
  color: var(--text);
  font-family: var(--font-body);
}

::-webkit-scrollbar { width: 4px; }
::-webkit-scrollbar-track { background: var(--bg); }
::-webkit-scrollbar-thumb { background: var(--pink); border-radius: 2px; }

/* =============================================
   SCREEN SYSTEM
============================================= */
.screen, .content-screen {
  display: none;
  min-height: 100vh; width: 100%;
  position: relative; overflow: hidden;
}
.screen.active, .content-screen.active { display: flex; }

.screen-enter { animation: screen-fade-in 0.5s ease forwards; }
@keyframes screen-fade-in {
  from { opacity: 0; transform: translateY(20px); }
  to   { opacity: 1; transform: translateY(0); }
}

/* Corner decorations */
.corner {
  position: absolute; width: 40px; height: 40px;
  border-color: var(--pink); border-style: solid; opacity: 0.35;
  pointer-events: none;
}
.corner-tl { top: 24px; left: 24px;   border-width: 2px 0 0 2px; }
.corner-tr { top: 24px; right: 24px;  border-width: 2px 2px 0 0; }
.corner-bl { bottom: 24px; left: 24px;  border-width: 0 0 2px 2px; }
.corner-br { bottom: 24px; right: 24px; border-width: 0 2px 2px 0; }

/* =============================================
   START SCREEN
============================================= */
#start-screen {
  flex-direction: column;
  align-items: center; justify-content: center;
  cursor: pointer; background: var(--bg);
}
.start-grid {
  position: absolute; inset: 0;
  background-image:
    linear-gradient(rgba(255,110,180,0.04) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255,110,180,0.04) 1px, transparent 1px);
  background-size: 60px 60px;
  animation: grid-drift 20s linear infinite;
  pointer-events: none;
}
@keyframes grid-drift {
  0%   { transform: perspective(500px) rotateX(15deg) translateY(0); }
  100% { transform: perspective(500px) rotateX(15deg) translateY(60px); }
}
.start-vignette {
  position: absolute; inset: 0;
  background: radial-gradient(ellipse at center, transparent 30%, var(--bg) 80%);
  pointer-events: none;
}
.start-particles {
  position: absolute; inset: 0; pointer-events: none;
}
.start-content {
  position: relative; z-index: 2; text-align: center;
  pointer-events: none;
}
.start-eyebrow {
  font-family: var(--font-mono); font-size: 10px;
  color: var(--pink); letter-spacing: 6px; opacity: 0.8; margin-bottom: 28px;
}
.start-name {
  font-family: var(--font-pixel); font-size: clamp(14px, 3vw, 22px);
  color: #fff; line-height: 2; margin-bottom: 8px;
  text-shadow: 0 0 40px var(--pink-glow), 0 0 80px rgba(192,132,252,0.3);
}
.start-sub {
  font-family: var(--font-mono); font-size: clamp(9px, 1.5vw, 12px);
  color: var(--lavender); letter-spacing: 4px; margin-bottom: 60px; opacity: 0.8;
}
.start-prompt {
  font-family: var(--font-pixel); font-size: 9px;
  color: var(--pink); animation: blink 1.2s steps(1) infinite; letter-spacing: 2px;
}
@keyframes blink { 0%,49%{opacity:1} 50%,100%{opacity:0} }

/* =============================================
   MENU SCREEN
============================================= */
#menu-screen {
  flex-direction: column; align-items: center; justify-content: center;
  background: var(--bg); padding: 40px 20px;
}
.menu-bg {
  position: absolute; inset: 0;
  background: radial-gradient(ellipse 80% 60% at 50% 40%, rgba(255,110,180,0.05) 0%, transparent 70%);
  pointer-events: none;
}
.menu-header { position: relative; z-index: 2; text-align: center; margin-bottom: 56px; }
.menu-eyebrow {
  font-family: var(--font-mono); font-size: 10px;
  color: var(--pink); letter-spacing: 5px; opacity: 0.6; margin-bottom: 20px;
}
.menu-title {
  font-family: var(--font-pixel); font-size: clamp(12px, 2.5vw, 20px);
  color: #fff; line-height: 1.9;
  text-shadow: 0 0 30px var(--pink-glow);
}
.menu-title span {
  display: block; font-size: 0.55em;
  color: var(--lavender); margin-top: 8px; letter-spacing: 4px;
}
.menu-nav { position: relative; z-index: 2; width: 100%; max-width: 360px; }
.menu-nav ul { list-style: none; display: flex; flex-direction: column; gap: 12px; }
.menu-nav li {
  font-family: var(--font-pixel); font-size: 11px;
  padding: 18px 24px;
  border: 1px solid rgba(255,110,180,0.2);
  background: rgba(255,110,180,0.03);
  cursor: pointer; position: relative; overflow: hidden;
  transition: all 0.3s ease; letter-spacing: 2px;
  display: flex; align-items: center; gap: 16px;
}
.menu-nav li::before {
  content: ''; position: absolute; left: 0; top: 0; bottom: 0;
  width: 3px; background: var(--pink);
  transform: scaleY(0); transition: transform 0.3s ease;
}
.menu-nav li::after {
  content: ''; position: absolute; inset: 0;
  background: linear-gradient(90deg, rgba(255,110,180,0.08), transparent);
  opacity: 0; transition: opacity 0.3s ease;
}
.menu-nav li:hover { border-color: var(--pink); transform: translateX(8px); color: var(--pink); }
.menu-nav li:hover::before { transform: scaleY(1); }
.menu-nav li:hover::after  { opacity: 1; }
.nav-num { font-size: 8px; color: var(--pink); opacity: 0.5; font-family: var(--font-mono); }
.nav-arrow { margin-left: auto; opacity: 0; transition: opacity 0.3s, transform 0.3s; }
.menu-nav li:hover .nav-arrow { opacity: 1; transform: translateX(4px); }

/* =============================================
   COMMON CONTENT SCREEN
============================================= */
.content-screen {
  flex-direction: column; align-items: center;
  padding: 80px 24px 60px; background: var(--bg);
}
.back-btn {
  position: absolute; top: 24px; left: 24px;
  font-family: var(--font-pixel); font-size: 9px;
  color: var(--pink); background: transparent;
  border: 1px solid rgba(255,110,180,0.3);
  padding: 10px 16px; cursor: pointer;
  transition: all 0.2s; z-index: 20; letter-spacing: 1px;
}
.back-btn:hover { background: var(--pink-dim); border-color: var(--pink); transform: translateX(-3px); }

.section-header { text-align: center; margin-bottom: 60px; z-index: 2; position: relative; }
.section-label {
  font-family: var(--font-mono); font-size: 10px;
  color: var(--pink); letter-spacing: 5px; opacity: 0.6; margin-bottom: 12px;
}
.section-title {
  font-family: var(--font-pixel); font-size: clamp(14px, 3vw, 24px);
  color: #fff; line-height: 1.6;
}
.section-line {
  width: 60px; height: 2px;
  background: linear-gradient(90deg, var(--pink), transparent);
  margin: 20px auto 0;
}

/* =============================================
   ABOUT
============================================= */
#about { padding-top: 100px; }
.about-layout {
  display: grid; grid-template-columns: 220px 1fr;
  gap: 48px; max-width: 860px; width: 100%;
  z-index: 2; position: relative; align-items: start;
}
.about-sidebar { display: flex; flex-direction: column; align-items: center; gap: 20px; }

.about-img-wrap { position: relative; width: 160px; height: 160px; }
.about-img-wrap::before {
  content: ''; position: absolute; inset: -4px; border-radius: 50%;
  background: conic-gradient(var(--pink), var(--lavender), var(--pink));
  animation: spin 6s linear infinite;
}
@keyframes spin { to { transform: rotate(360deg); } }
.about-img-wrap::after {
  content: ''; position: absolute; inset: 0;
  border-radius: 50%; background: #fff;
}
.about-img {
  position: relative; z-index: 1;
  width: 152px; height: 152px;
  object-fit: cover; border-radius: 50%; margin: 4px;
}

.about-name-badge {
  font-family: var(--font-pixel); font-size: 9px;
  color: var(--pink); text-align: center; line-height: 2.2; letter-spacing: 1px;
}

/* SNS links */
.sns-links { display: flex; flex-direction: column; gap: 8px; width: 100%; }
.sns-link {
  display: flex; align-items: center; gap: 10px;
  font-family: var(--font-mono); font-size: 9px;
  color: var(--text-dim); text-decoration: none;
  border: 1px solid rgba(255,110,180,0.15);
  padding: 8px 12px; border-radius: 2px;
  background: rgba(255,110,180,0.03);
  transition: all 0.2s;
}
.sns-link:hover { color: var(--pink); border-color: var(--pink); background: var(--pink-dim); }
.sns-icon { font-size: 13px; flex-shrink: 0; }

.skill-tags { display: flex; flex-wrap: wrap; gap: 6px; justify-content: center; }
.skill-tag {
  font-family: var(--font-mono); font-size: 9px;
  color: var(--lavender); border: 1px solid rgba(192,132,252,0.3);
  padding: 4px 8px; border-radius: 2px; background: rgba(192,132,252,0.05);
}

.about-body p {
  font-size: 13px; line-height: 2.4;
  color: rgba(240,232,245,0.85); margin-bottom: 20px; font-weight: 300;
}
.about-body strong { color: var(--pink); font-weight: 500; }
.about-body em { color: var(--lavender); font-style: normal; }

.about-section-title {
  font-family: var(--font-pixel); font-size: 10px;
  color: var(--pink); margin: 32px 0 16px; letter-spacing: 2px;
}
.skill-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; margin-bottom: 24px; }
.skill-card {
  background: rgba(255,110,180,0.04); border: 1px solid rgba(255,110,180,0.1);
  border-left: 3px solid var(--pink); padding: 12px 14px; border-radius: 2px;
}
.skill-card-name {
  font-family: var(--font-mono); font-size: 9px;
  color: var(--pink); margin-bottom: 6px; letter-spacing: 1px;
}
.skill-card-desc { font-size: 11px; color: var(--text-dim); line-height: 1.7; }

/* About FX */
.about-fx { position: absolute; inset: 0; pointer-events: none; z-index: 0; }
@keyframes petal-fall {
  0%  { transform: translateY(-40px) rotate(0deg); opacity: 0; }
  20% { opacity: 0.6; }
  80% { opacity: 0.6; }
  100%{ transform: translateY(100vh) rotate(180deg); opacity: 0; }
}
.petal {
  position: absolute; font-size: 14px;
  animation: petal-fall linear infinite;
}

/* =============================================
   WORKS
============================================= */
#works { padding-top: 100px; }
.works-grid {
  display: grid; grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 28px; max-width: 960px; width: 100%; z-index: 2; position: relative;
}
.work-card {
  background: var(--bg2); border: 1px solid rgba(255,110,180,0.1);
  border-radius: 4px; overflow: hidden;
  text-decoration: none; color: var(--text);
  transition: all 0.4s ease; display: flex; flex-direction: column; position: relative;
}
.work-card::before {
  content: ''; position: absolute; top: 0; left: 0; right: 0; height: 1px;
  background: linear-gradient(90deg, transparent, var(--pink), transparent);
  transform: scaleX(0); transition: transform 0.4s ease;
}
.work-card:hover::before { transform: scaleX(1); }
.work-card:hover {
  border-color: rgba(255,110,180,0.4); transform: translateY(-8px);
  box-shadow: 0 20px 60px rgba(0,0,0,0.6), 0 0 40px rgba(255,110,180,0.08);
}
.work-img-wrap { position: relative; overflow: hidden; height: 180px; }
.work-img-wrap img { width: 100%; height: 100%; object-fit: cover; transition: transform 0.6s ease; }
.work-card:hover .work-img-wrap img { transform: scale(1.06); }
.work-img-overlay {
  position: absolute; inset: 0; background: rgba(13,10,18,0.65);
  display: flex; align-items: center; justify-content: center;
  opacity: 0; transition: opacity 0.3s;
}
.work-card:hover .work-img-overlay { opacity: 1; }
.work-img-overlay span {
  font-family: var(--font-mono); font-size: 11px;
  color: var(--pink); letter-spacing: 3px;
  border: 1px solid var(--pink); padding: 8px 16px;
}
.work-body { padding: 20px; flex: 1; }
.work-title-row { display: flex; align-items: center; gap: 10px; margin-bottom: 16px; }
.work-num { font-family: var(--font-mono); font-size: 9px; color: var(--pink); opacity: 0.5; }
.work-title { font-family: var(--font-pixel); font-size: 10px; color: var(--pink); letter-spacing: 1px; }
.work-meta { display: flex; flex-direction: column; gap: 10px; }
.work-meta-label {
  font-family: var(--font-mono); font-size: 8px;
  color: var(--pink); letter-spacing: 2px; opacity: 0.6; margin-bottom: 4px;
}
.work-meta-text { font-size: 11px; line-height: 2; color: var(--text-dim); }

/* Works FX */
.works-fx { position: absolute; inset: 0; pointer-events: none; z-index: 0; }
@keyframes float-shape {
  0%  { transform: translateY(100vh) rotate(0deg); opacity: 0; }
  10% { opacity: 0.15; }
  90% { opacity: 0.15; }
  100%{ transform: translateY(-20vh) rotate(360deg); opacity: 0; }
}
.fx-shape { position: absolute; animation: float-shape linear infinite; color: var(--pink); }

/* =============================================
   ILLUSTRATION
============================================= */
#illustration { padding-top: 100px; }
.illust-grid {
  display: grid; grid-template-columns: repeat(3, 1fr);
  gap: 20px; max-width: 720px; width: 100%; z-index: 2; position: relative;
}
.illust-item {
  position: relative; cursor: zoom-in; overflow: hidden;
  border-radius: 4px; border: 1px solid rgba(255,110,180,0.12); aspect-ratio: 3/4;
}
.illust-item a { display: block; width: 100%; height: 100%; }
.illust-item img {
  width: 100%; height: 100%; object-fit: cover;
  transition: transform 0.5s ease; display: block;
}
.illust-item:hover img { transform: scale(1.08); }
.illust-hover {
  position: absolute; inset: 0;
  background: linear-gradient(to top, rgba(13,10,18,0.9) 0%, transparent 60%);
  display: flex; align-items: flex-end; padding: 16px;
  opacity: 0; transition: opacity 0.3s; pointer-events: none;
}
.illust-item:hover .illust-hover { opacity: 1; }
.illust-hover-text { font-family: var(--font-mono); font-size: 9px; color: var(--pink); letter-spacing: 2px; }

/* Modal */
.modal {
  position: fixed; inset: 0; background: rgba(0,0,0,0.92);
  display: flex; align-items: center; justify-content: center;
  opacity: 0; pointer-events: none; transition: opacity 0.3s ease; z-index: 1000;
}
.modal:target { opacity: 1; pointer-events: auto; }
.modal .modal-bg { position: absolute; inset: 0; }
.modal img {
  max-width: 90vw; max-height: 90vh; border-radius: 4px;
  position: relative; z-index: 1; animation: zoom-in 0.3s ease;
  border: 1px solid rgba(255,110,180,0.2);
  box-shadow: 0 0 80px rgba(255,110,180,0.15);
}
.modal-close {
  position: absolute; top: 24px; right: 24px; z-index: 2;
  font-family: var(--font-mono); font-size: 10px;
  color: var(--pink); text-decoration: none;
  border: 1px solid rgba(255,110,180,0.3); padding: 8px 14px; transition: all 0.2s;
}
.modal-close:hover { background: var(--pink-dim); border-color: var(--pink); }
@keyframes zoom-in {
  from { transform: scale(0.9); opacity: 0; }
  to   { transform: scale(1);   opacity: 1; }
}

/* Illustration FX */
.illust-fx { position: absolute; inset: 0; pointer-events: none; z-index: 0; overflow: hidden; }
@keyframes float-star {
  0%  { transform: translateY(110vh) rotate(0deg); opacity: 0; }
  15% { opacity: 0.5; }
  85% { opacity: 0.5; }
  100%{ transform: translateY(-10vh) rotate(360deg); opacity: 0; }
}
.fx-star { position: absolute; color: var(--pink); animation: float-star linear infinite; }

/* =============================================
   CONTACT
============================================= */
#contact { padding-top: 100px; justify-content: flex-start; }
.contact-layout {
  display: grid; grid-template-columns: 1fr 1fr;
  gap: 60px; max-width: 800px; width: 100%; z-index: 2; position: relative; align-items: start;
}
.contact-info-title {
  font-family: var(--font-pixel); font-size: 10px;
  color: var(--pink); margin-bottom: 20px; letter-spacing: 2px;
}
.contact-info-text { font-size: 13px; line-height: 2.4; color: var(--text-dim); margin-bottom: 28px; }
.contact-detail { display: flex; align-items: center; gap: 12px; margin-bottom: 14px; }
.contact-detail-icon {
  width: 32px; height: 32px;
  border: 1px solid rgba(255,110,180,0.2);
  display: flex; align-items: center; justify-content: center;
  font-size: 14px; flex-shrink: 0;
}
.contact-detail-text {
  font-family: var(--font-mono); font-size: 10px; color: var(--text-dim);
  word-break: break-all;
}
.contact-detail-link {
  font-family: var(--font-mono); font-size: 10px; color: var(--text-dim);
  text-decoration: none; word-break: break-all; transition: color 0.2s;
}
.contact-detail-link:hover { color: var(--pink); }

.contact-form { display: flex; flex-direction: column; gap: 16px; }
.form-group { display: flex; flex-direction: column; gap: 8px; }
.form-label {
  font-family: var(--font-mono); font-size: 9px;
  color: var(--pink); letter-spacing: 3px; opacity: 0.7;
}
.contact-form input,
.contact-form textarea {
  background: rgba(255,110,180,0.03); color: var(--text);
  border: 1px solid rgba(255,110,180,0.2); border-radius: 2px;
  padding: 14px 16px; font-family: var(--font-mono); font-size: 11px;
  width: 100%; transition: all 0.3s; outline: none;
}
.contact-form input:focus,
.contact-form textarea:focus {
  border-color: var(--pink); background: rgba(255,110,180,0.06);
  box-shadow: 0 0 0 1px rgba(255,110,180,0.2);
}
.contact-form textarea { resize: vertical; min-height: 120px; }
.contact-form button[type="submit"] {
  background: var(--pink); color: #fff;
  font-family: var(--font-pixel); font-size: 11px;
  padding: 16px; border: none; cursor: pointer;
  transition: all 0.3s; letter-spacing: 2px; position: relative; overflow: hidden;
}
.contact-form button[type="submit"]:hover { background: var(--lavender); }

/* Contact FX */
.contact-fx { position: absolute; inset: 0; pointer-events: none; z-index: 0; }
@keyframes dot-rise {
  0%  { transform: translateY(0); opacity: 0; }
  50% { opacity: 0.4; }
  100%{ transform: translateY(-100vh); opacity: 0; }
}
.fx-dot { position: absolute; border-radius: 50%; background: var(--pink); animation: dot-rise linear infinite; }

/* =============================================
   RESPONSIVE
============================================= */
@media (max-width: 768px) {
  .about-layout { grid-template-columns: 1fr; }
  .about-sidebar { flex-direction: column; align-items: center; }
  .skill-grid { grid-template-columns: 1fr; }
  .illust-grid { grid-template-columns: repeat(2, 1fr); }
  .contact-layout { grid-template-columns: 1fr; gap: 40px; }
  .works-grid { grid-template-columns: 1fr; }
  .content-screen { padding: 80px 16px 60px; }
}
@media (max-width: 480px) {
  .illust-grid { grid-template-columns: 1fr; }
  .about-layout { gap: 32px; }
}
