
/* ===== RESET ===== */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

:root {
  --beige: #f5ede0;
  --beige-dark: #ecdcc8;
  --slate: #5a7180;
  --slate-dark: #445e6d;
  --slate-light: #6e8898;
  --text-dark: #2c3a42;
  --text-mid: #4a5a63;
  --text-light: #7a8f9a;
  --accent: #c8a97e;
  --white: #fff;
  --form-bg: #f0f4f6;
}

body {
  font-family: 'Barlow', sans-serif;
  background: #e6ecef;
  color: var(--text-dark);
  min-height: 100vh;
}

/* ===== APP LAYOUT ===== */
.app { display: flex; min-height: 100vh; }

/* ===== FORM PANEL ===== */
.form-panel {
  width: 420px;
  min-width: 380px;
  background: var(--white);
  border-right: 1.5px solid #dde4e8;
  display: flex;
  flex-direction: column;
  overflow-y: auto;
  position: sticky;
  top: 0;
  height: 100vh;
  box-shadow: 4px 0 24px rgba(44,58,66,0.08);
  z-index: 10;
}

.form-header {
  background: var(--slate);
  padding: 26px 28px 20px;
  color: var(--white);
  flex-shrink: 0;
}

.form-header h1 {
  font-family: 'Barlow Condensed', sans-serif;
  font-size: 22px;
  font-weight: 700;
  letter-spacing: 2px;
  text-transform: uppercase;
  margin-bottom: 4px;
}

.form-header p { font-size: 12.5px; color: rgba(255,255,255,0.65); font-weight: 300; }

.form-body { padding: 22px 26px 30px; flex: 1; overflow-y: auto; }

.section-label {
  font-family: 'Barlow Condensed', sans-serif;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 2.5px;
  text-transform: uppercase;
  color: var(--slate);
  margin: 20px 0 10px;
  padding-bottom: 5px;
  border-bottom: 2px solid var(--beige-dark);
}
.section-label:first-child { margin-top: 0; }

label {
  display: block;
  font-size: 10.5px;
  font-weight: 600;
  color: var(--text-light);
  margin-bottom: 4px;
  margin-top: 9px;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

input[type="text"], input[type="email"], input[type="tel"], textarea, select {
  width: 100%;
  padding: 8px 12px;
  border: 1.5px solid #d8e2e8;
  border-radius: 6px;
  font-family: 'Barlow', sans-serif;
  font-size: 13.5px;
  color: var(--text-dark);
  background: var(--form-bg);
  transition: border-color 0.2s, box-shadow 0.2s;
  outline: none;
}
input:focus, textarea:focus, select:focus {
  border-color: var(--slate);
  box-shadow: 0 0 0 3px rgba(90,113,128,0.12);
  background: #fff;
}
textarea { resize: vertical; min-height: 68px; }

.add-btn {
  display: flex; align-items: center; gap: 6px;
  margin-top: 10px; padding: 8px 14px;
  border: 1.5px dashed var(--slate-light);
  background: none; border-radius: 6px;
  color: var(--slate); font-size: 12.5px; font-weight: 600;
  cursor: pointer; width: 100%; justify-content: center;
  transition: background 0.2s;
}
.add-btn:hover { background: rgba(90,113,128,0.06); }

.entry-card {
  background: var(--form-bg);
  border: 1.5px solid #d8e2e8;
  border-radius: 7px;
  padding: 11px 13px;
  margin-top: 9px;
  position: relative;
}
.entry-card .remove-btn {
  position: absolute; top: 7px; right: 10px;
  background: none; border: none;
  color: #c0392b; font-size: 17px; cursor: pointer;
  font-weight: 700; line-height: 1;
}
.entry-card label { margin-top: 5px; }
.entry-card label:first-of-type { margin-top: 0; }

.row-2 { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; }

.photo-wrapper { display: flex; justify-content: center; margin: 4px 0 10px; }
.photo-upload-area {
  border: 2px dashed #c8d8e0; border-radius: 50%;
  width: 90px; height: 90px;
  display: flex; flex-direction: column;
  align-items: center; justify-content: center;
  cursor: pointer; position: relative; overflow: hidden;
  background: var(--form-bg); transition: border-color 0.2s;
}
.photo-upload-area:hover { border-color: var(--slate); }
.photo-upload-area img { position: absolute; width: 100%; height: 100%; object-fit: cover; }
.photo-upload-area span { font-size: 10px; color: var(--text-light); text-align: center; z-index: 1; pointer-events: none; }
.photo-upload-area input { display: none; }

.generate-btn {
  width: 100%; padding: 13px;
  background: var(--slate); color: var(--white);
  border: none; border-radius: 8px;
  font-family: 'Barlow', sans-serif; font-size: 13.5px;
  font-weight: 700; letter-spacing: 1px; text-transform: uppercase;
  cursor: pointer; margin-top: 22px;
  display: flex; align-items: center; justify-content: center; gap: 8px;
  transition: background 0.2s, transform 0.1s;
}
.generate-btn:hover { background: var(--slate-dark); transform: translateY(-1px); }

/* ===== PREVIEW PANEL ===== */
.preview-panel {
  flex: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: 36px 20px 60px;
  background: #dce4e8;
  overflow-y: auto;
}

.preview-toolbar {
  width: 100%; max-width: 820px;
  display: flex; align-items: center; justify-content: space-between;
  margin-bottom: 18px;
}
.preview-toolbar h2 {
  font-family: 'Barlow Condensed', sans-serif;
  font-size: 17px; font-weight: 700;
  letter-spacing: 2px; text-transform: uppercase;
  color: var(--slate-dark);
}
.download-btn {
  display: flex; align-items: center; gap: 7px;
  padding: 10px 20px;
  background: var(--slate); color: #fff;
  border: none; border-radius: 7px;
  font-family: 'Barlow', sans-serif; font-size: 13px; font-weight: 600;
  cursor: pointer; transition: background 0.2s;
}
.download-btn:hover { background: var(--slate-dark); }

/* ===== CV PREVIEW ===== */
#cv-preview {
  width: 794px;
  min-height: 1123px;
  background: var(--beige);
  display: flex;
  flex-wrap: nowrap;
  box-shadow: 0 10px 50px rgba(44,58,66,0.22);
  border-radius: 2px;
  overflow: hidden;
}

/* LEFT SIDEBAR */
.cv-left {
  width: 260px;
  min-width: 260px;
  flex-shrink: 0;
  background: var(--beige);
  display: flex;
  flex-direction: column;
  padding: 36px 22px 30px;
}

.cv-photo-wrap {
  width: 140px; height: 140px;
  border-radius: 50%;
  overflow: hidden;
  margin: 0 auto 22px;
  background: #d8c8b0;
  border: 4px solid rgba(255,255,255,0.7);
  display: flex; align-items: center; justify-content: center;
  box-shadow: 0 4px 18px rgba(90,113,128,0.18);
}
.cv-photo-wrap img { width: 100%; height: 100%; object-fit: cover; display: block; }
.cv-photo-placeholder { width: 60px; height: 60px; opacity: 0.3; }

.cv-fullname {
  font-family: 'Playfair Display', serif;
  font-size: 30px;
  font-weight: 800;
  line-height: 1.05;
  color: var(--text-dark);
  text-transform: uppercase;
  margin-bottom: 6px;
  word-break: break-word;
}

.cv-subtitle {
  font-family: 'Barlow Condensed', sans-serif;
  font-size: 10px;
  font-weight: 600;
  letter-spacing: 2.5px;
  text-transform: uppercase;
  color: var(--text-mid);
  margin-bottom: 14px;
  line-height: 1.5;
}

.cv-divider {
  width: 44px;
  height: 3px;
  background: var(--slate);
  margin-bottom: 20px;
}

.cv-left-section { margin-bottom: 20px; }

.cv-left-heading {
  font-family: 'Barlow Condensed', sans-serif;
  font-size: 10px;
  font-weight: 700;
  letter-spacing: 2.5px;
  text-transform: uppercase;
  color: var(--slate);
  margin-bottom: 8px;
}

.cv-left-text {
  font-size: 10px;
  line-height: 1.7;
  color: var(--text-mid);
}

.cv-list-item {
  font-size: 10px;
  line-height: 1.6;
  color: var(--text-mid);
  padding-left: 0;
}
.cv-list-item::before { content: '- '; }

.cv-contact-line {
  font-size: 10px;
  line-height: 1.75;
  color: var(--text-mid);
}

/* RIGHT MAIN */
.cv-right {
  flex: 1;
  min-width: 0;
  background: var(--slate);
  display: flex;
  flex-direction: column;
  padding: 0 0 30px;
}

.cv-section-banner {
  background: var(--beige);
  padding: 10px 26px;
  margin: 26px 0 14px;
}
.cv-section-banner:first-child { margin-top: 26px; }

.cv-section-banner-title {
  font-family: 'Barlow Condensed', sans-serif;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 3px;
  text-transform: uppercase;
  color: var(--slate-dark);
}

.cv-right-body { padding: 0 26px; }

.cv-job { margin-bottom: 16px; }

.cv-job-title {
  font-family: 'Barlow', sans-serif;
  font-size: 12px;
  font-weight: 700;
  color: var(--white);
  margin-bottom: 2px;
}

.cv-job-sub {
  font-family: 'Barlow', sans-serif;
  font-size: 10.5px;
  font-weight: 600;
  color: var(--beige-dark);
  margin-bottom: 5px;
  opacity: 0.85;
}

.cv-job-bullet {
  font-size: 10px;
  color: rgba(255,255,255,0.8);
  line-height: 1.65;
  padding-left: 0;
}
.cv-job-bullet::before { content: '- '; }

.cv-edu-name {
  font-family: 'Barlow', sans-serif;
  font-size: 12px;
  font-weight: 700;
  color: var(--white);
  margin-bottom: 2px;
}

.cv-edu-sub {
  font-size: 10.5px;
  font-weight: 600;
  color: var(--beige-dark);
  margin-bottom: 5px;
  opacity: 0.85;
}

.cv-edu-item {
  font-size: 10px;
  color: rgba(255,255,255,0.8);
  line-height: 1.65;
}
.cv-edu-item::before { content: '- '; }

.cv-interest-item {
  font-size: 10px;
  color: rgba(255,255,255,0.82);
  line-height: 1.7;
}
.cv-interest-item::before { content: '- '; }

/* ===== UTIL ===== */
.mb-8 { margin-bottom: 8px; }
