@import url('https://fonts.googleapis.com/css2?family=IBM+Plex+Mono:wght@400;500;600;700&family=IBM+Plex+Sans:ital,wght@0,300;0,400;0,500;0,600;0,700;1,400&display=swap');

/* =============================================
   DESIGN TOKENS
   ============================================= */
:root {
  --bg-page: #eef0f3;
  --bg-resume: #ffffff;
  --bg-sidebar: #18253d;
  --bg-sidebar-surface: #1f3050;
  --sidebar-text: #dde8f5;
  --sidebar-muted: #8bafc9;
  --sidebar-accent: #6cb4f0;
  --sidebar-border: rgba(255, 255, 255, 0.13);
  --sidebar-pill-bg: rgba(108, 180, 240, 0.13);
  --sidebar-pill-border: rgba(108, 180, 240, 0.3);
  --text-main: #1a1e27;
  --text-muted: #57606a;
  --text-light: #8b949e;
  --accent: #005f73;
  --accent-hover: #004d5e;
  --accent-light: rgba(0, 95, 115, 0.09);
  --accent-pill-border: rgba(0, 95, 115, 0.22);
  --border: #e5e7eb;
  --border-strong: #d1d5db;
  --font-mono: 'IBM Plex Mono', monospace;
  --font-main: 'IBM Plex Sans', -apple-system, BlinkMacSystemFont, "Segoe UI", Helvetica, Arial, sans-serif;
  --radius: 9px;
  --radius-sm: 6px;
  --radius-pill: 999px;
}

/* =============================================
   RESET & BASE
   ============================================= */
*, *::before, *::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

body {
  font-family: var(--font-main);
  font-size: 10px;
  line-height: 1.4;
  color: var(--text-main);
  background: var(--bg-page);
  display: flex;
  justify-content: center;
  padding: 40px 20px;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

a { color: inherit; text-decoration: none; }

/* =============================================
   RESUME — A4, 2-COLUMN GRID
   ============================================= */
.resume {
  width: 210mm;
  min-height: 297mm;
  max-height: 297mm;
  background: var(--bg-resume);
  box-shadow: 0 4px 32px rgba(0,0,0,0.14), 0 0 0 1px rgba(0,0,0,0.05);
  display: grid;
  grid-template-columns: 183px 1fr;
  overflow: hidden;
}

/* =============================================
   SIDEBAR
   ============================================= */
.sidebar {
  background: var(--bg-sidebar);
  padding: 16px 13px 14px;
  display: flex;
  flex-direction: column;
  gap: 0;
  overflow: hidden;
}

.sidebar-section {
  display: flex;
  flex-direction: column;
  gap: 5px;
  margin-bottom: 10px;
}

.sidebar-section:last-child {
  margin-bottom: 0;
}

/* Profile photo */
.profile-photo {
  display: flex;
  justify-content: center;
  padding-bottom: 2px;
}

.profile-photo img {
  width: 150px;
  height: 150px;
  border-radius: 50%;
  object-fit: cover;
  object-position: top center;
  border: 2px solid rgba(108, 180, 240, 0.55);
  box-shadow: 0 0 0 4px rgba(108, 180, 240, 0.1), 0 4px 12px rgba(0,0,0,0.28);
}

.sidebar-title {
  font-size: 8.5px;
  font-weight: 700;
  color: var(--sidebar-muted);
  text-transform: uppercase;
  letter-spacing: 1px;
  font-family: var(--font-mono);
  border-bottom: 1px solid var(--sidebar-border);
  padding-bottom: 4px;
  margin-bottom: 1px;
}

/* ---- Contact ---- */
.contact-list {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.contact-item {
  display: flex;
  align-items: flex-start;
  gap: 6px;
  font-size: 8.8px;
  color: var(--sidebar-text);
  opacity: 0.85;
  line-height: 1.35;
}

.contact-item i {
  color: var(--sidebar-accent);
  width: 11px;
  text-align: center;
  font-size: 9px;
  flex-shrink: 0;
  margin-top: 0.5px;
}

.contact-item a { color: var(--sidebar-text); opacity: 0.85; }
.contact-item a:hover { color: var(--sidebar-accent); opacity: 1; }

/* ---- Skills ---- */
.skill-group { margin-bottom: 5px; }
.skill-group:last-child { margin-bottom: 0; }

.skill-title {
  font-size: 9px;
  font-weight: 600;
  color: var(--sidebar-text);
  margin-bottom: 4px;
  opacity: 0.9;
}

.skill-list {
  display: flex;
  flex-wrap: wrap;
  gap: 3px;
}

.skill-tag {
  background: rgba(255,255,255,0.05);
  border: 1px solid var(--sidebar-border);
  color: var(--sidebar-muted);
  padding: 2px 6px;
  border-radius: var(--radius-pill);
  font-size: 8.2px;
  font-weight: 500;
}

.skill-tag.highlight {
  background: var(--sidebar-pill-bg);
  color: var(--sidebar-accent);
  border-color: var(--sidebar-pill-border);
  font-weight: 600;
}

/* ---- Sidebar list items ---- */
.list-item { margin-bottom: 5px; }
.list-item:last-child { margin-bottom: 0; }

.list-item-title {
  font-weight: 600;
  font-size: 9.5px;
  color: var(--sidebar-text);
}

.list-item-desc {
  font-size: 8.2px;
  color: var(--sidebar-muted);
  line-height: 1.4;
}

/* ---- Availability badge ---- */
.sidebar-badge {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 4px;
  padding: 2.5px 6px;
  border-radius: var(--radius-pill);
  border: 1px solid rgba(48, 209, 88, 0.25);
  background: rgba(48, 209, 88, 0.07);
  color: #3fb950;
  font-size: 6.8px;
  font-weight: 600;
  font-family: var(--font-mono);
  letter-spacing: 0.1px;
  max-width: 100%;
  white-space: normal;
  line-height: 1.2;
  text-align: center;
}

.sidebar-badge::before {
  content: '';
  width: 5px;
  height: 5px;
  border-radius: 50%;
  background: #3fb950;
  box-shadow: 0 0 5px rgba(63,185,80,0.7);
  flex-shrink: 0;
  animation: pulse-dot 2s ease infinite;
}

@keyframes pulse-dot {
  0%, 100% { box-shadow: 0 0 0 0 rgba(63,185,80,0.5); }
  50%       { box-shadow: 0 0 0 5px rgba(63,185,80,0); }
}

/* =============================================
   MAIN CONTENT
   ============================================= */
.main-content {
  background: var(--bg-resume);
  padding: 18px 22px 20px 18px;
  display: flex;
  flex-direction: column;
  gap: 10px;
  overflow: hidden;
}

.name {
  font-weight: 700;
  color: var(--text-main);
  letter-spacing: -0.5px;
  line-height: 1.1;
  font-family: var(--font-mono);
  margin-bottom: 2px;
}

.profile-tagline {
  display: block;
  font-family: var(--font-mono);
  font-weight: 600;
  font-size: 9px;
  color: var(--accent);
  padding: 5px 11px;
  background: var(--accent-light);
  border-left: 3px solid var(--accent);
  border-radius: 0 var(--radius-sm) var(--radius-sm) 0;
  letter-spacing: 0.2px;
}

/* ---- Sections ---- */
.section {
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.section-title {
  font-size: 9px;
  font-weight: 700;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 0.9px;
  font-family: var(--font-mono);
  border-bottom: 1px solid var(--border);
  padding-bottom: 3px;
  margin-bottom: 1px;
}

.profile-text {
  font-size: 9.5px;
  line-height: 1.5;
  color: var(--text-main);
}

.profile-text strong {
  font-weight: 600;
  color: var(--accent);
}

/* ---- Entries ---- */
.entry {
  display: flex;
  flex-direction: column;
  gap: 1px;
  padding: 8px 10px;
  background: #f8fafc;
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  border-left: 3px solid var(--accent);
}

.entry-header {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  gap: 6px;
}

.entry-title {
  font-size: 10px;
  font-weight: 700;
  color: var(--text-main);
  line-height: 1.2;
}

.entry-date {
  font-size: 8.5px;
  font-weight: 500;
  color: var(--text-light);
  white-space: nowrap;
  font-family: var(--font-mono);
  flex-shrink: 0;
}

.entry-subtitle {
  font-size: 9px;
  font-weight: 500;
  color: var(--text-muted);
}

.entry-subtitle a {
  color: var(--accent);
  text-decoration: underline;
  text-decoration-color: var(--accent-light);
  text-underline-offset: 1px;
}

.entry-subtitle a:hover { color: var(--accent-hover); }

.entry-description {
  margin-top: 2px;
  padding-left: 10px;
}

.entry-description li {
  font-size: 10px;
  line-height: 1.4;
  color: var(--text-main);
  margin-bottom: 1px;
  position: relative;
  list-style-type: none;
}

.entry-description li::before {
  content: "›";
  color: var(--accent);
  font-weight: bold;
  position: absolute;
  left: -10px;
}

.entry-description li:last-child { margin-bottom: 0; }

.entry-description strong {
  font-weight: 600;
  color: var(--text-main);
}

/* ---- Tech pills ---- */
.pill-row {
  display: flex;
  flex-wrap: wrap;
  gap: 3px;
  margin-top: 4px;
}

.pill-row span {
  background: rgba(255,255,255,0.8);
  border: 1px solid var(--border-strong);
  color: var(--text-muted);
  padding: 1px 7px;
  border-radius: var(--radius-pill);
  font-size: 8.5px;
  font-weight: 500;
}

.pill-row .pill-highlight {
  background: var(--accent-light);
  color: var(--accent);
  border-color: var(--accent-pill-border);
  font-weight: 600;
}

/* =============================================
   PRINT
   ============================================= */
@media print {
  body { background: none; padding: 0; }
  .resume {
    box-shadow: none;
    width: 210mm;
    height: 297mm;
    max-height: 297mm;
    overflow: hidden;
  }
  .sidebar {
    -webkit-print-color-adjust: exact;
    print-color-adjust: exact;
  }
}