@import url("https://fonts.googleapis.com/css2?family=Inter:wght@300;400;500;600;700;800&display=swap");

/* ==========================
   ROOT
========================== */
:root {

  /*root*/
  --a4-width: 210mm;
  --a4-min-height: 297mm;

  --bg-color: #f1f5f9;
  --bg-container-color: #ffffff;

  --text-regular-color: #555555;
  --text-regular-font-size: 1rem;
  --text-regular-font-weight: 400;

  --date-color: var(--text-regular-color);
  --date-font-size: 0.8rem;
  --date-font-weight: var(--text-regular-font-weight);

  --external-link-color: var(--text-regular-color);
  --external-link-font-size: var(--text-regular-font-size);
  --external-link-font-weight: var(--text-regular-font-weight);

  /* NAV BAR */
  --nav-bar-bg-color: #ffffffe6;
  --nav-bar-backdrop-filter: blur(8px);
  --nav-bar-border-bottom: 1px solid #e5e7eb;

  --nav-bar-name-color: #050505;
  --nav-bar-name-font-size: 0.85rem;
  --nav-bar-name-font-weight: 700;

  --btn-color: #050505;
  --btn-bg-color: #f1f5f9;
  --btn-active-color: #ffffff;
  --btn-active-bg-color: #0f172a;
  --btn-hover-color: #0f172a;
  --btn-hover-bg-color: #e2e2e2;

  /* PERSONAL */
  --personal-name-color: #050505;
  --personal-name-font-size: 2.4rem;
  --personal-name-font-weight: 800;

  --personal-job-title-color: #4b4b4b;
  --personal-job-title-font-size: 1.5rem;
  --personal-job-title-font-weight: 700;

  --personal-location-color: var(--text-regular-color);
  --personal-location-font-size: var(--text-regular-font-size);
  --personal-location-font-weight: var(--text-regular-font-weight);

  --personal-contact-item-color: var(--external-link-color);
  --personal-contact-item-font-size: var(--external-link-font-size);
  --personal-contact-item-font-weight: var(--external-link-font-weight);

  --personal-photo-width: 130px;
  --personal-photo-height: 160px;
  --personal-photo-border-radius: 6px;
  --personal-photo-object-fit: cover;

  /* SECTION */
  --section-header-color: #050505;
  --section-header-font-size: 1.05rem;
  --section-header-font-weight: 700;

  --section-divider-height: 1px;
  --section-divider-bg-color: #646464;

  --section-sub-header-color: var(--text-regular-color);
  --section-sub-header-font-size: var(--text-regular-font-size);
  --section-sub-header-font-weight: var(--text-regular-font-weight);

  /* ITEM */
  --item-title-color: #050505;
  --item-title-font-size: 1rem;
  --item-title-font-weight: 600;

  --item-sub-title-color: var(--text-regular-color);
  --item-sub-title-font-size: var(--text-regular-font-size);
  --item-sub-title-font-weight: var(--text-regular-font-weight);

  /* SUB-ITEM */
  --sub-item-role-color: var(--text-regular-color);
  --sub-item-role-font-size: var(--text-regular-font-size);
  --sub-item-role-font-weight: var(--text-regular-font-weight);

  --sub-item-content-color: #4b4b4b;
  --sub-item-content-font-size: 1rem;
  --sub-item-content-font-weight: 400;

  --sub-item-tag-color: var(--text-regular-color);
  --sub-item-tag-bg-color: #e2e2e2;
  --sub-item-tag-font-size: 0.8rem;
  --sub-item-tag-font-weight: var(--text-regular-font-weight);
}

/* ==========================
   GLOBAL TEXT BEHAVIOR
========================== */
p,
li {
  text-align: justify;
  text-align-last: left;
  hyphens: none;
  word-break: normal;
}

/* ==========================
   BODY
========================== */
body {
  margin: 0;
  padding: 0;
  font-family: "Inter", Arial, sans-serif;
  background-color: var(--bg-color);
}

/* ==========================
   NAV BAR
========================== */
.cv-nav {
  position: sticky;
  top: 0;
  z-index: 10;

  display: flex;
  justify-content: space-between;
  align-items: center;

  padding: 0.75rem 2.5rem;
  background-color: var(--nav-bar-bg-color);
  backdrop-filter: var(--nav-bar-backdrop-filter);
  border-bottom: var(--nav-bar-border-bottom);
}

.cv-nav-left {
  display: flex;
  align-items: center;
  gap: 1.5rem;
}

.cv-nav-name {
  font-size: var(--nav-bar-name-font-size);
  font-weight: var(--nav-bar-name-font-weight);
  letter-spacing: 0.08em;
}

.cv-lang-switch {
  display: flex;
  gap: 0.25rem;
  padding: 0.2rem;
  background-color: var(--btn-bg-color);
  border-radius: 6px;
}

.lang-btn {
  font-size: 0.75rem;
  font-weight: 700;
  padding: 0.3rem 0.7rem;
  border: none;
  background: none;
  cursor: pointer;
  border-radius: 4px;
  color: var(--btn-color);
}

.lang-btn.active {
  background-color: var(--btn-active-bg-color);
  color: var(--btn-active-color);
}

.lang-btn:hover:not(.active) {
  background-color: var(--btn-hover-bg-color);
  color: var(--btn-hover-color);
}

.cv-print-btn {
  font-size: 0.8rem;
  font-weight: 700;
  padding: 0.45rem 1.2rem;
  border: none;
  border-radius: 6px;
  cursor: pointer;
  background-color: var(--btn-active-bg-color);
  color: var(--btn-active-color);
}

.cv-print-btn:hover {
  background-color: var(--btn-hover-bg-color);
  color: var(--btn-hover-color);
}

/* ==========================
   CONTAINER
========================== */
.cv-container {
  width: var(--a4-width);
  min-height: var(--a4-min-height);
  margin: 1.5rem auto 3.5rem auto;
  padding: 22mm;
  background-color: var(--bg-container-color);
  box-shadow:
    0 0 1px rgba(0, 0, 0, 0.12),
    0 10px 30px rgba(0, 0, 0, 0.08),
    0 25px 60px rgba(0, 0, 0, 0.05);
}

/* ==========================
   SELECTIVE PRINTING
========================== */
.cv-item, .cv-sub-item {
  position: relative;
}

.cv-item-checkbox {
  position: absolute;
  left: -2.2rem;
  top: 0.2rem;
  cursor: pointer;
  transform: scale(1.2);
}

/* ==========================
   PERSONAL
========================== */
.cv-personal {
  position: relative;
  margin-bottom: 2.5rem;
}

.cv-personal-left {
  padding-right: 160px;
}

.cv-personal-left-name {
  font-size: var(--personal-name-font-size);
  font-weight: var(--personal-name-font-weight);
  line-height: 1.1;
  margin-bottom: 0.2rem;
  color: var(--personal-name-color);
}

.cv-personal-left-job-title {
  font-size: var(--personal-job-title-font-size);
  font-weight: var(--personal-job-title-font-weight);
  margin-bottom: 1.2rem;
  margin-top: 0.2rem;
}

.cv-personal-left-contact-list {
  margin-bottom: 0.8rem;
}

.cv-personal-left-contact-list-item {
  font-size: var(--personal-contact-item-font-size);
  font-weight: var(--personal-contact-item-font-weight);
  line-height: 1.45;
}

.cv-personal-left-location {
  color: var(--personal-location-color);
  font-size: var(--personal-location-font-size);
  font-weight: var(--personal-location-font-weight);
}

.cv-personal-right {
  position: absolute;
  top: 0;
  right: 0;
}

.cv-personal-right-photo {
  width: var(--personal-photo-width);
  height: var(--personal-photo-height);
  object-fit: var(--personal-photo-object-fit);
  border-radius: var(--personal-photo-border-radius);
}

/* ==========================
   SECTION
========================== */
.cv-section {
  position: relative;
  margin-bottom: 2.5rem;
}

.cv-section-header {
  font-size: var(--section-header-font-size);
  font-weight: var(--section-header-font-weight);
  letter-spacing: 0.08em;
  margin: 0 0 0.25rem 0;
  color: var(--section-header-color);
}

.cv-section-divider {
  width: 100%;
  border-bottom: var(--section-divider-height) solid var(--section-divider-bg-color);
  margin-bottom: 0.7rem;
}

.cv-section-sub-header {
  font-size: var(--section-sub-header-font-size);
  font-weight: var(--section-sub-header-font-weight);
  line-height: 1.6;
  margin-bottom: 1.2rem;
  color: var(--section-sub-header-color);
}

/* ==========================
   ITEM
========================== */
.cv-item-list {
  list-style: disc;
  padding-left: 1.2rem;
}

.cv-item {
  margin-bottom: 1.4rem;
}

.cv-item-title {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  gap: 1rem;
}

.cv-item-title-text {
  font-weight: var(--item-title-font-weight);
  font-size: var(--item-title-font-size);
  color: var(--item-title-color);
}

.cv-item-sub-title {
  margin-top: 0.3rem;
  font-size: var(--item-sub-title-font-size);
  font-weight: var(--item-sub-title-font-weight);
  color: var(--item-sub-title-color);
}

.cv-item-date {
  font-size: var(--date-font-size);
  color: var(--date-color);
  white-space: nowrap;
}

/* ==========================
   SUB ITEM
========================== */
.cv-sub-item-list {
  list-style: circle;
  padding-left: 1.4rem;
  margin-top: 0.6rem;
}

.cv-sub-item {
  margin-top: 0.8rem;
}

.cv-sub-item-role {
  display: flex;
  justify-content: space-between;
  gap: 1rem;
}

.cv-sub-item-role-text {
  font-weight: var(--sub-item-role-font-weight);
  color: var(--sub-item-role-color);
}

.cv-sub-item-date {
  font-size: var(--date-font-size);
  color: var(--date-color);
}

.cv-sub-item-content-list {
  list-style: square;
  padding-left: 1.2rem;
  margin-top: 0.4rem;
  font-size: var(--sub-item-content-font-size);
  line-height: 1.55;
  color: var(--sub-item-content-color);
}

.cv-tag-list {
  display: flex;
  flex-wrap: wrap;
  gap: 0.35rem;
}

.cv-tag {
  font-size: var(--sub-item-tag-font-size);
  padding: 0.2rem 0.5rem;
  border-radius: 4px;
  background-color: var(--sub-item-tag-bg-color);
  color: var(--sub-item-tag-color); 
}

/* ==========================
   INFO BANNER
========================== */
.cv-info-banner {
  width: calc(var(--a4-width) + 150px);
  max-width: 95vw;
  margin: 2rem auto 0 auto;
  background-color: #f0f9ff;
  border: 1px solid #bae6fd;
  color: #0369a1;
  padding: 1.5rem 2rem;
  border-radius: 8px;
  font-size: 0.95rem;
  text-align: center;
  line-height: 1.5;
  box-sizing: border-box;
}

.cv-info-banner-date {
  display: block;
  margin-top: 0.4rem;
  font-size: 0.85rem;
  opacity: 0.75;
}

.cv-info-banner strong {
  color: #0c4a6e;
  font-weight: 700;
}

/* Orientation Layouts */
.orientation-horizontal {
  display: flex !important;
  flex-direction: row;
  flex-wrap: nowrap;
  gap: 1.5rem;
  list-style: none !important;
  padding-left: 0 !important;
}

.orientation-horizontal > li {
  flex: 1;
  min-width: 0; /* Esnek kutu taşmasını önler */
  margin-bottom: 0 !important;
}

.orientation-horizontal .cv-item-checkbox {
  position: static;
  margin-right: 0.5rem;
  transform: scale(1.1);
  vertical-align: middle;
}

/* Hiyerarşik Durumlar */
.hierarchy-hidden {
  display: none !important;
}

.text-dimmed {
  opacity: 0.4;
  transition: opacity 0.2s ease;
}

/* ==========================
   LINKS
========================== */
.cv-personal-left-contact-list-item-link {
  color: var(--personal-contact-item-color);;
  text-decoration: none;
}

.cv-personal-left-contact-list-item-link:hover {
  text-decoration: underline;
}

.cv-external-link {
  color: inherit;
  text-decoration: none;
}

.cv-external-link::after {
  content: "";
  display: inline-block;
  width: 0.85em;
  height: 0.85em;
  margin-left: 0.35rem;
  background-color: currentColor;
  -webkit-mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath d='M14,3V5H17.59L7.76,14.83L9.17,16.24L19,6.41V10H21V3M19,19H5V5H12V3H5C3.89,3 3,3.9 3,5V19A2,2 0 0,0 5,21H19A2,2 0 0,0 21,19V12H19V19Z'%3E%3C/path%3E%3C/svg%3E") no-repeat center;
  mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath d='M14,3V5H17.59L7.76,14.83L9.17,16.24L19,6.41V10H21V3M19,19H5V5H12V3H5C3.89,3 3,3.9 3,5V19A2,2 0 0,0 5,21H19A2,2 0 0,0 21,19V12H19V19Z'%3E%3C/path%3E%3C/svg%3E") no-repeat center;
  mask-size: contain;
  -webkit-mask-size: contain;
  opacity: 0.4;
  vertical-align: text-bottom;
  transition: opacity 0.2s ease;
}

.cv-external-link:hover {
  text-decoration: underline;
}

.cv-external-link:hover::after {
  opacity: 1;
}

/* ==========================
   PRINT
========================== */
@media print {
  body { background: none; }
  .no-print, .cv-item-checkbox { display: none !important; }
  .not-selected-for-print { display: none !important; }
  
  /* 2 Sayfa Sınırı İçin Sıkılaştırma */
  :root {
    --bg-color: #fff;
    --bg-container-color: #fff;
    --personal-name-font-size: 2rem;
    --personal-job-title-font-size: 1.2rem;
    --text-regular-font-size: 0.9rem;
    --sub-item-content-font-size: 0.85rem;
  }

  .cv-section { margin-bottom: 1.2rem; }
  .cv-item { margin-bottom: 0.8rem; }
  .cv-sub-item { margin-top: 0.4rem; }
  .cv-sub-item-content-list { margin-top: 0.2rem; }
  
  .cv-container {
    width: 100%;
    margin: 0;
    padding: 18mm;
    box-shadow: none;
  }

  @page {
    size: A4;
    margin: 0;
  }
}
