/* 
   ── Redesigned Portfolio Design System ─────────────────────────────── 
   High-impact Apple-style Bento Grids, Mesh Gradients, and Glassmorphism.
*/

:root {
  --bg: #030303;
  --bg-tile: rgba(255, 255, 255, 0.04);
  --fg: #ffffff;
  --dim: #94a3b8;
  --acc: #38bdf8;
  --acc-rgb: 56, 189, 248;
  --border: rgba(255, 255, 255, 0.1);
  --glow: rgba(56, 189, 248, 0.2);
  
  --font-main: 'Outfit', 'Inter', -apple-system, sans-serif;
}

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

html {
  scroll-behavior: smooth;
}

/* ── Immersive Background ─────────────────────────────────────────── */
.gui-wrapper {
  color: var(--fg);
  font-family: var(--font-main);
  line-height: 1.6;
  position: relative;
  min-height: 100%;
  background: var(--bg);
  overflow-x: hidden;
  /* Scale App to 1.2x */
  zoom: 1.1;
  -moz-transform: scale(1.1);
  -moz-transform-origin: top center;
  transform: scale(1.1);
  transform-origin: top center;
  /* Premium Mesh Gradient */
  background-image: 
    radial-gradient(at 0% 0%, hsla(203, 80%, 15%, 0.4) 0px, transparent 50%),
    radial-gradient(at 100% 0%, hsla(280, 80%, 10%, 0.3) 0px, transparent 50%),
    radial-gradient(at 50% 100%, hsla(190, 80%, 15%, 0.3) 0px, transparent 50%);
}

/* Interactive Cursor Glow */
.gui-wrapper::after {
  content: '';
  position: fixed;
  top: 0; left: 0;
  width: 100%; height: 100%;
  background: radial-gradient(800px circle at var(--mouse-x, 50%) var(--mouse-y, 50%), rgba(var(--acc-rgb), 0.07), transparent 60%);
  pointer-events: none;
  z-index: 0;
}

/* ── Typography ───────────────────────────────────────────────────── */
h1, h2, h3, h4 {
  font-family: var(--font-main);
  font-weight: 800;
  letter-spacing: -0.03em;
}

::selection {
  background: var(--acc);
  color: #000;
}

/* ── Sticky Premium Nav ────────────────────────────────────────────── */
.navbar {
  position: sticky;
  top: 0;
  width: 100%;
  padding: 20px 0;
  backdrop-filter: blur(20px) saturate(180%);
  -webkit-backdrop-filter: blur(20px) saturate(180%);
  background: rgba(3, 3, 3, 0.6);
  border-bottom: 1px solid var(--border);
  z-index: 100;
  transition: all 0.4s cubic-bezier(0.16, 1, 0.3, 1);
}

.navbar.scrolled {
  padding: 12px 0;
  background: rgba(3, 3, 3, 0.85);
}

.nav-container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 32px;
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.logo {
  font-size: 1.5rem;
  font-weight: 900;
  background: linear-gradient(135deg, #fff 0%, var(--dim) 100%);
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
  cursor: pointer;
}

.nav-links {
  display: flex;
  gap: 32px;
}

.nav-links a {
  color: var(--dim);
  text-decoration: none;
  font-size: 0.9rem;
  font-weight: 500;
  transition: all 0.3s ease;
  position: relative;
}

.nav-links a:hover, .nav-links a.active {
  color: var(--fg);
}

/* ── Hero Section (The Landing) ───────────────────────────────────── */
.hero {
  max-width: 1100px;
  margin: 0 auto;
  padding: 120px 32px 80px;
  text-align: center;
  position: relative;
  z-index: 1;
}

.hero h1 {
  font-size: 5.5rem;
  line-height: 1.1;
  margin-bottom: 24px;
  background: linear-gradient(to bottom, #ffffff 60%, rgba(255,255,255,0.4));
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
  text-wrap: balance;
}

.hero h2 {
  font-size: 1.5rem;
  font-weight: 500;
  color: var(--acc);
  margin-bottom: 48px;
  opacity: 0.9;
  letter-spacing: 0.05em;
  text-transform: uppercase;
}

.hero-content {
  font-size: 1.25rem;
  color: var(--dim);
  max-width: 680px;
  margin: 0 auto 56px;
  text-align: center;
  line-height: 1.8;
  font-weight: 300;
}

.hero-actions {
  display: flex;
  justify-content: center;
  gap: 20px;
}

.btn {
  padding: 12px 28px;
  border-radius: 100px;
  font-weight: 600;
  text-decoration: none;
  transition: all 0.3s cubic-bezier(0.16, 1, 0.3, 1);
  display: inline-flex;
  align-items: center;
  gap: 8px;
}

.btn-primary {
  background: var(--fg);
  color: var(--bg);
}

.btn-primary:hover {
  transform: scale(1.05);
  background: transparent;
  color: var(--fg);
  box-shadow: inset 0 0 0 2px var(--fg), 0 0 30px rgba(var(--acc-rgb), 0.3);
}

.btn-secondary {
  background: rgba(255,255,255,0.03);
  color: var(--fg);
  border: 1px solid var(--border);
}

.btn-secondary:hover {
  background: var(--fg);
  color: var(--bg);
  border-color: var(--fg);
  box-shadow: 0 0 30px rgba(var(--acc-rgb), 0.2);
}

/* ── Bento Grid System ────────────────────────────────────────────── */
.bento-grid {
  max-width: 1200px;
  margin: 0 auto 120px;
  padding: 0 32px;
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  grid-auto-rows: minmax(180px, auto);
  gap: 20px;
}

.bento-tile {
  background: var(--bg-tile);
  border: 1px solid var(--border);
  border-radius: 24px;
  padding: 32px;
  position: relative;
  overflow: hidden;
  transition: transform 0.4s cubic-bezier(0.16, 1, 0.3, 1), border 0.3s ease;
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  display: flex;
  flex-direction: column;
}

.bento-tile:hover {
  transform: translateY(-8px);
  border-color: rgba(var(--acc-rgb), 0.4);
  background: rgba(255, 255, 255, 0.06);
}

/* Bento Tile Sizes */
.tile-2x2 { grid-column: span 2; grid-row: span 2; }
.tile-2x1 { grid-column: span 2; }
.tile-1x2 { grid-row: span 2; }
.tile-4x1 { grid-column: span 4; }
.tile-4x2 { grid-column: span 4; grid-row: span 2; }

/* ── Experience Bento Tiles ───────────────────────────────────────── */
.timeline-item {
  margin-bottom: 24px;
}

.timeline-item h3 {
  font-size: 1.15rem;
  margin-bottom: 4px;
}

.timeline-item .role {
  color: var(--acc);
  font-size: 0.9rem;
  font-weight: 500;
}

/* ── Projects Bento Tiles ─────────────────────────────────────────── */
.project-tile {
  background-size: cover;
  background-position: center;
}

.project-tile .overlay {
  position: absolute;
  top: 0; left: 0; width: 100%; height: 100%;
  background: linear-gradient(to bottom, transparent 30%, rgba(0,0,0,0.9));
  padding: 32px;
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
}

.project-tile h3 { font-size: 1.5rem; margin-bottom: 8px; }
.project-tile p { font-size: 0.9rem; color: var(--dim); margin-bottom: 16px; }

/* ── Skills & Stats Tiles ────────────────────────────────────────── */
.skill-pills {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 16px;
}

.skill-pill {
  background: rgba(255,255,255,0.07);
  border: 1px solid rgba(255,255,255,0.15);
  padding: 8px 16px;
  border-radius: 100px;
  font-size: 0.8rem;
  font-weight: 500;
  color: #fff;
  transition: all 0.3s ease;
}

.skill-pill:hover {
  background: rgba(56, 189, 248, 0.1);
  border-color: var(--acc);
}

.stat-item {
  margin-top: auto;
}

.stat-value {
  font-size: 3rem;
  font-weight: 900;
  line-height: 1;
  background: linear-gradient(to bottom, #fff, var(--dim));
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
}

.stat-label {
  font-size: 0.8rem;
  color: var(--dim);
  text-transform: uppercase;
  letter-spacing: 1px;
}

/* ── CTA Section ────────────────────────────────────────────────────── */
.cta-section {
  max-width: 1200px;
  margin: 0 auto 120px;
  padding: 0 32px;
}

.cta-card {
  background: linear-gradient(135deg, rgba(var(--acc-rgb), 0.08) 0%, rgba(255,255,255,0.02) 100%);
  border: 1px solid rgba(var(--acc-rgb), 0.15);
  border-radius: 32px;
  padding: 56px 40px;
  text-align: center;
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
}

.cta-card h2 {
  font-size: 2.2rem;
  margin-bottom: 12px;
  background: linear-gradient(to bottom, #fff, var(--dim));
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
}

.cta-card p {
  font-size: 1.25rem;
  color: var(--dim);
  margin-bottom: 40px;
  max-width: 600px;
  margin-left: auto;
  margin-right: auto;
}

/* ── Redesigned Footer ─────────────────────────────────────────────── */
.footer {
  border-top: 1px solid var(--border);
  padding: 60px 0;
  margin-top: 120px;
}

.footer-content {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 32px;
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.footer p {
  color: var(--dim);
  font-size: 0.95rem;
}

.footer strong {
  color: #fff;
}

.footer-links {
  display: flex;
  gap: 24px;
}

.footer-links a {
  color: var(--dim);
  text-decoration: none;
  font-size: 0.9rem;
  font-weight: 500;
  transition: all 0.3s ease;
}

.footer-links a:hover {
  color: var(--acc);
}

/* ── Animations ───────────────────────────────────────────────────── */
section {
  opacity: 0;
  transform: translateY(30px);
  transition: all 1s cubic-bezier(0.16, 1, 0.3, 1);
}

section.visible {
  opacity: 1;
  transform: translateY(0);
}

@keyframes float {
  0% { transform: translateY(0px); }
  50% { transform: translateY(-10px); }
  100% { transform: translateY(0px); }
}

/* ── Responsive ────────────────────────────────────────────────────── */
@media (max-width: 1024px) {
  .bento-grid { grid-template-columns: repeat(2, 1fr); }
  .hero h1 { font-size: 4rem; }
}

@media (max-width: 640px) {
  .bento-grid { grid-template-columns: 1fr; }
  .hero h1 { font-size: 3rem; }
  .tile-2x2, .tile-2x1 { grid-column: span 1; }
}
/* ── Wallpaper Selection Window ───────────────────────────────── */
.wallpaper-settings-layout {
  height: 100%;
  overflow: hidden;
}

.settings-main {
  height: 100%;
  padding: 30px;
  overflow-y: auto;
}

.settings-header {
  font-size: 24px;
  font-weight: 600;
  margin-bottom: 24px;
  color: white;
  letter-spacing: -0.2px;
}

.wallpaper-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 24px;
}

.wallpaper-item {
  display: flex;
  flex-direction: column;
  gap: 10px;
  cursor: pointer;
}

.wallpaper-thumb {
  width: 100%;
  aspect-ratio: 1 / 1;
  background-size: cover;
  background-position: center;
  border-radius: 14px;
  border: 4px solid transparent;
  transition: all 0.3s cubic-bezier(0.16, 1, 0.3, 1);
  box-shadow: 0 4px 10px rgba(0,0,0,0.2);
}

.wallpaper-item:hover .wallpaper-thumb {
  transform: scale(1.04) translateY(-2px);
  box-shadow: 0 10px 20px rgba(0,0,0,0.4);
}

.wallpaper-item.active .wallpaper-thumb {
  box-shadow: 0 0 0 2px rgba(255, 255, 255, 0.6), 0 12px 25px rgba(0,0,0,0.5);
}

.wallpaper-name {
  font-size: 13px;
  text-align: center;
  color: rgba(255, 255, 255, 0.7);
  font-weight: 500;
}

.wallpaper-item.active .wallpaper-name {
  color: white;
  font-weight: 600;
}

/* ── Appearance Popover (macOS Style) ────────────────────────────── */
.appearance-popover {
  width: 300px;
  padding: 8px;
  display: flex;
  flex-direction: column;
  gap: 10px;
  background: transparent;
  color: #fff;
}

.appearance-row-top {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
}

.appearance-toggle {
  background: rgba(255, 255, 255, 0.06);
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 12px;
  padding: 14px 12px;
  display: flex;
  flex-direction: column;
  gap: 8px;
  cursor: pointer;
  transition: all 0.2s ease;
}

.appearance-toggle:hover {
  background: rgba(255, 255, 255, 0.1);
}

.appearance-toggle .toggle-icon {
  width: 28px;
  height: 28px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.1);
  display: flex;
  align-items: center;
  justify-content: center;
  transition: background 0.3s ease;
}

.appearance-toggle.active .toggle-icon {
  background: #ff9f0a;
}

.appearance-toggle span {
  font-size: 0.8rem;
  font-weight: 600;
  opacity: 0.9;
}

.appearance-section {
  background: rgba(255, 255, 255, 0.06);
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 14px;
  padding: 14px;
}

.appearance-section.clickable {
  cursor: pointer;
  transition: all 0.2s ease;
}

.appearance-section.clickable:hover {
  background: rgba(255, 255, 255, 0.1);
}

.section-label {
  font-size: 0.75rem;
  font-weight: 700;
  color: #fff;
  margin-bottom: 14px;
  opacity: 0.9;
}

.appearance-colors {
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.appearance-dot-wrapper {
  width: 26px;
  height: 26px;
  border-radius: 50%;
  padding: 2px;
  border: 2px solid transparent;
  cursor: pointer;
  transition: border-color 0.2s ease;
}

.appearance-dot-wrapper.active {
  border-color: #ff9f0a;
}

.appearance-dot {
  width: 100%;
  height: 100%;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: inset 0 0 2px rgba(0,0,0,0.2);
}

.appearance-wallpaper-thumb {
  width: 46px;
  height: 46px;
  border-radius: 10px;
  background-size: cover;
  background-position: center;
  border: 1px solid rgba(255,255,255,0.1);
}

.section-title {
  font-size: 0.9rem;
  font-weight: 700;
  color: #fff;
}

.section-subtitle {
  font-size: 0.75rem;
  color: rgba(255, 255, 255, 0.5);
  margin-top: 2px;
}

.notch-icon {
  width: 22px;
  height: 32px;
  border: 2px solid rgba(255,255,255,0.6);
  border-radius: 4px;
  position: relative;
}

.notch-icon::after {
  content: '';
  position: absolute;
  top: 0;
  left: 50%;
  transform: translateX(-50%);
  width: 10px;
  height: 2px;
  background: white;
  border-radius: 0 0 2px 2px;
}

/* ── Overriding Menu Dropdown for Appearance ──────────────────────── */
#global-menu-dropdown.appearance-mode {
  padding: 0;
  border: 1px solid rgba(255,255,255,0.15);
  box-shadow: 0 20px 40px rgba(0,0,0,0.4);
}
