/* ═══════════════════════════════════════════════
   SHARED STYLES — Mr. A Portfolio
═══════════════════════════════════════════════ */

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

:root {
  --sunrise-deep:    #1a0a2e;
  --sunrise-purple:  #3d1a5e;
  --sunrise-magenta: #7b2d5e;
  --sunrise-coral:   #FF6B6B;
  --sunrise-orange:  #FF9F1C;
  --sunrise-peach:   #ffb580;
  --sunrise-gold:    #FFD166;
  --sunrise-pink:    #ffcba4;
  --text-bright:     #fff8f0;
  --text-soft:       rgba(255,245,230,0.75);
  --text-muted:      rgba(255,235,210,0.45);
}

html { scroll-behavior: smooth; }

body {
  font-family: 'Plus Jakarta Sans', Georgia, serif;
  background: var(--sunrise-deep);
  color: var(--text-bright);
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
  cursor: none;
}

/* ─── TEXT SELECTION ─── */
::selection { background: rgba(255,107,107,0.4); color: #fff; }
::-moz-selection { background: rgba(255,107,107,0.4); color: #fff; }

/* ─── NOISE OVERLAY ─── */
body::before {
  content: '';
  position: fixed;
  inset: 0;
  z-index: 9990;
  pointer-events: none;
  opacity: 0.04;
  background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 256 256' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='noise'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='4' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23noise)'/%3E%3C/svg%3E");
  background-repeat: repeat;
  background-size: 256px 256px;
}

/* ─── SCROLL PROGRESS BAR ─── */
.scroll-progress {
  position: fixed;
  top: 0;
  left: 0;
  height: 3px;
  background: linear-gradient(90deg, var(--sunrise-coral), var(--sunrise-gold));
  z-index: 10001;
  width: 0;
  transition: width 0.1s linear;
}

/* ─── VIDEO BACKGROUND ─── */
.video-bg {
  position: fixed;
  inset: 0;
  z-index: 0;
  overflow: hidden;
}
.video-bg video {
  width: 100%; height: 100%;
  object-fit: cover;
  opacity: 0.55;
  filter: saturate(1.3) brightness(0.75);
}
.video-bg::after {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(160deg, rgba(26,10,46,0.72) 0%, rgba(61,26,94,0.45) 25%, rgba(123,45,94,0.3) 50%, rgba(255,111,107,0.15) 75%, rgba(255,159,28,0.25) 100%);
}

/* ─── NAVBAR ─── */
.navbar {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 1000;
  padding: 1rem 1.5rem;
  transition: background 0.3s, backdrop-filter 0.3s;
}
.navbar.scrolled {
  background: rgba(26,10,46,0.85);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border-bottom: 1px solid rgba(255,180,120,0.08);
}
.navbar-inner {
  max-width: 1100px;
  margin: 0 auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
}
.navbar-logo {
  font-size: 1.1rem;
  font-weight: 800;
  background: linear-gradient(135deg, var(--text-bright) 0%, var(--sunrise-gold) 100%);
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
  text-decoration: none;
}
.navbar-links {
  display: flex;
  align-items: center;
  gap: 1.5rem;
  list-style: none;
}
.navbar-link {
  font-size: 0.72rem;
  font-weight: 600;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--text-muted);
  text-decoration: none;
  transition: color 0.2s;
}
.navbar-link:hover,
.navbar-link.active {
  color: var(--sunrise-gold);
}
.navbar-burger {
  display: none;
  flex-direction: column;
  gap: 5px;
  background: none;
  border: none;
  cursor: pointer;
  padding: 4px;
}
.navbar-burger span {
  display: block;
  width: 22px;
  height: 2px;
  background: var(--text-soft);
  border-radius: 2px;
  transition: transform 0.3s, opacity 0.3s;
}
.navbar-burger.open span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
.navbar-burger.open span:nth-child(2) { opacity: 0; }
.navbar-burger.open span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }
.navbar-mobile {
  display: none;
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: rgba(26,10,46,0.95);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  z-index: 999;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 2rem;
}
.navbar-mobile.open { display: flex; }
.navbar-mobile a {
  font-size: 1.2rem;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--text-soft);
  text-decoration: none;
  transition: color 0.2s;
}
.navbar-mobile a:hover,
.navbar-mobile a.active { color: var(--sunrise-gold); }

@media (max-width: 700px) {
  .navbar-links { display: none; }
  .navbar-burger { display: flex; }
}

/* ─── HERO ─── */
.hero {
  position: relative;
  z-index: 10;
  min-height: 60vh;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  padding: 2rem 1.5rem 4rem;
}
.hero-glass {
  background: linear-gradient(135deg, rgba(26,10,46,0.6) 0%, rgba(61,26,94,0.45) 60%, rgba(255,111,107,0.08) 100%);
  backdrop-filter: blur(12px) saturate(1.2);
  -webkit-backdrop-filter: blur(12px) saturate(1.2);
  border: 1px solid rgba(255,180,120,0.12);
  border-radius: 24px;
  padding: 3rem 4rem 2.5rem;
  max-width: 800px;
  width: 100%;
  opacity: 0;
  transform: translateY(24px) scale(0.97);
  animation: heroReveal 1.1s cubic-bezier(0.22,1,0.36,1) 0.2s forwards;
}
@keyframes heroReveal { to { opacity: 1; transform: translateY(0) scale(1); } }
.hero-name {
  font-size: clamp(2.2rem, 6vw, 4.5rem);
  font-weight: 800;
  letter-spacing: -0.02em;
  line-height: 0.95;
  background: linear-gradient(135deg, var(--text-bright) 0%, var(--sunrise-pink) 40%, var(--sunrise-gold) 70%, var(--sunrise-orange) 100%);
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
  margin-bottom: 0.75rem;
}
.hero-subtitle {
  font-size: clamp(0.9rem, 2vw, 1.2rem);
  font-weight: 300;
  font-style: italic;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--sunrise-peach);
  margin-bottom: 1.5rem;
}
.hero-divider {
  width: 48px;
  height: 2px;
  background: linear-gradient(90deg, var(--sunrise-coral), var(--sunrise-gold));
  border-radius: 2px;
  margin: 0 auto 1.5rem;
  opacity: 0.8;
}
.hero-motto {
  font-size: clamp(0.82rem, 1.4vw, 0.95rem);
  font-weight: 400;
  color: var(--text-soft);
  letter-spacing: 0.05em;
  max-width: 500px;
  margin: 0 auto;
  line-height: 1.7;
}

/* ─── BACK LINK ─── */
.back-link {
  position: relative;
  z-index: 10;
  display: flex;
  justify-content: center;
  padding: 0 1.5rem 2rem;
}
.back-link a {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-size: 0.75rem;
  font-weight: 600;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  color: var(--text-muted);
  text-decoration: none;
  transition: color 0.2s;
}
.back-link a:hover { color: var(--sunrise-gold); }

/* ─── CONTENT ─── */
.content { position: relative; z-index: 10; }

.section-label {
  font-size: 0.65rem;
  font-weight: 600;
  letter-spacing: 0.28em;
  text-transform: uppercase;
  color: var(--sunrise-gold);
  margin-bottom: 1rem;
}

/* ─── CTA LINK ─── */
.cta-link {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  padding: 0.9rem 2.2rem;
  border-radius: 999px;
  background: linear-gradient(135deg, var(--sunrise-coral) 0%, var(--sunrise-orange) 100%);
  color: #fff;
  font-size: 0.9rem;
  font-weight: 700;
  letter-spacing: 0.05em;
  text-decoration: none;
  transition: transform 0.25s ease, box-shadow 0.25s ease;
  box-shadow: 0 4px 24px rgba(255,107,107,0.3);
}
.cta-link:hover {
  transform: translateY(-2px) scale(1.02);
  box-shadow: 0 8px 32px rgba(255,107,107,0.45);
}
.cta-arrow { font-size: 1.1rem; transition: transform 0.2s; }
.cta-link:hover .cta-arrow { transform: translateX(3px); }

/* ─── FOOTER ─── */
.footer {
  position: relative;
  z-index: 10;
  padding: 4rem 1.5rem 3rem;
  text-align: center;
  border-top: 1px solid rgba(255,180,120,0.08);
}
.footer-inner { max-width: 600px; margin: 0 auto; }
.footer-tagline {
  font-size: 0.72rem;
  letter-spacing: 0.25em;
  text-transform: uppercase;
  color: var(--text-muted);
  margin-bottom: 1.5rem;
}
.footer-note {
  margin-top: 2rem;
  font-size: 0.68rem;
  letter-spacing: 0.12em;
  color: var(--text-muted);
}
.flag-art {
  margin-top: 1rem;
  font-size: 0.7rem;
  line-height: 1;
  letter-spacing: 0;
  color: var(--text-muted);
  text-align: center;
  user-select: none;
}

/* ───CLOCKS ─── */
.clocks-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 1rem;
  margin-top: 2rem;
}
.clock-card {
  text-align: center;
  padding: 1.5rem 1rem;
  background: rgba(255,255,255,0.03);
  border: 1px solid rgba(255,180,120,0.08);
  border-radius: 12px;
  transition: border-color 0.3s;
}
.clock-card:hover { border-color: rgba(255,209,102,0.2); }
.clock-city {
  font-size: 0.6rem;
  font-weight: 600;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--text-muted);
  margin-bottom: 8px;
}
.clock-time {
  font-size: 1.6rem;
  font-weight: 800;
  background: linear-gradient(135deg, var(--sunrise-coral), var(--sunrise-gold));
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
  font-variant-numeric: tabular-nums;
}
.clock-date {
  font-size: 0.65rem;
  color: var(--text-muted);
  margin-top: 4px;
}

@media (max-width: 600px) {
  .clocks-grid { grid-template-columns: repeat(2, 1fr); }
}

/* ─── CUSTOM CURSOR ─── */
.cursor-dot {
  position: fixed;
  top: 0; left: 0;
  width: 8px; height: 8px;
  border-radius: 50%;
  background: var(--sunrise-gold);
  pointer-events: none;
  z-index: 9999;
  transform: translate(-50%, -50%);
  transition: width 0.2s, height 0.2s, background 0.2s;
  mix-blend-mode: difference;
}
.cursor-ring {
  position: fixed;
  top: 0; left: 0;
  width: 36px; height: 36px;
  border-radius: 50%;
  border: 1.5px solid rgba(255,209,102,0.4);
  pointer-events: none;
  z-index: 9998;
  transform: translate(-50%, -50%);
  transition: width 0.3s, height 0.3s, border-color 0.3s;
}
.cursor-dot.hover { width: 14px; height: 14px; background: var(--sunrise-coral); }
.cursor-ring.hover { width: 52px; height: 52px; border-color: rgba(255,107,107,0.5); }

/* ─── CREDIT BUTTON ─── */
.credit-btn {
  position: fixed;
  bottom: 1.5rem;
  right: 1.5rem;
  z-index: 100;
  width: 32px;
  height: 32px;
  border-radius: 50%;
  border: 1px solid rgba(255,180,120,0.25);
  background: rgba(26,10,46,0.7);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  color: var(--sunrise-gold);
  font-size: 0.85rem;
  font-weight: 800;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: background 0.2s, border-color 0.2s;
}
.credit-btn:hover {
  background: rgba(255,209,102,0.15);
  border-color: rgba(255,209,102,0.4);
}
.credit-popup {
  position: fixed;
  bottom: 4rem;
  right: 1.5rem;
  z-index: 100;
  background: rgba(26,10,46,0.85);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border: 1px solid rgba(255,180,120,0.15);
  border-radius: 12px;
  padding: 1rem 1.2rem;
  max-width: 260px;
  opacity: 0;
  transform: translateY(8px);
  pointer-events: none;
  transition: opacity 0.25s, transform 0.25s;
}
.credit-popup.open {
  opacity: 1;
  transform: translateY(0);
  pointer-events: auto;
}
.credit-popup-title {
  font-size: 0.6rem;
  font-weight: 600;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--sunrise-gold);
  margin-bottom: 6px;
}
.credit-popup-text {
  font-size: 0.75rem;
  color: var(--text-soft);
  line-height: 1.6;
}

/* ─── PRELOADER ─── */
.preloader {
  position: fixed;
  inset: 0;
  z-index: 10000;
  background: var(--sunrise-deep);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  transition: opacity 0.6s ease, visibility 0.6s ease;
}
.preloader.hidden { opacity: 0; visibility: hidden; }
.preloader-name {
  font-size: clamp(3rem, 8vw, 6rem);
  font-weight: 800;
  letter-spacing: -0.02em;
  background: linear-gradient(135deg, var(--text-bright) 0%, var(--sunrise-pink) 40%, var(--sunrise-gold) 70%, var(--sunrise-orange) 100%);
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
  opacity: 0;
  transform: translateY(20px);
  animation: preloaderName 0.8s cubic-bezier(0.22,1,0.36,1) 0.3s forwards;
}
.preloader-line {
  width: 0;
  height: 2px;
  background: linear-gradient(90deg, var(--sunrise-coral), var(--sunrise-gold));
  border-radius: 2px;
  margin-top: 1.2rem;
  animation: preloaderLine 0.8s cubic-bezier(0.22,1,0.36,1) 0.7s forwards;
}
@keyframes preloaderName { to { opacity: 1; transform: translateY(0); } }
@keyframes preloaderLine { to { width: 60px; } }

/* ─── PAGE TRANSITION ─── */
.page-transition {
  position: fixed;
  inset: 0;
  background: var(--sunrise-deep);
  z-index: 10002;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.3s ease;
}
.page-transition.active {
  opacity: 1;
  pointer-events: auto;
}
