/* ===========================
   Raphael Berger – styles.css
   =========================== */

:root {
  --color-blue: #4A9FE5;
  --color-blue-hover: #3A8BD0;
  --color-blue-light: #EBF4FC;
  --color-text: #1E1E1E;
  --color-text-secondary: #5A5A5A;
  --color-bg: #FAFBFC;
  --color-white: #FFFFFF;
  --color-border: #E4E7EB;
  --font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  --radius: 10px;
}

/* ---- Reset ---- */

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

html {
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  text-rendering: optimizeLegibility;
}

body {
  font-family: var(--font-family);
  font-size: 16px;
  line-height: 1.6;
  color: var(--color-text);
  background-color: var(--color-bg);
  min-height: 100vh;
}

/* ---- Split layout ---- */

.layout {
  display: grid;
  grid-template-columns: 58% 42%;
  height: 100vh;
  overflow: hidden;
}

.content {
  display: flex;
  flex-direction: column;
  justify-content: center;
  padding: 2.5rem 3.5rem 1.25rem 6rem;
}

.content-inner {
  max-width: 560px;
  padding-bottom: 1.5rem;
}

/* ---- Visual (right panel) ---- */

.visual {
  position: relative;
  overflow: hidden;
  margin: 1.5rem 1.5rem 1.5rem 0;
  border-radius: 16px;
}

.visual::after {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(135deg, rgba(250, 251, 252, 0.08) 0%, transparent 60%);
  pointer-events: none;
}

.visual-img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center 30%;
  display: block;
  filter: saturate(0.85) brightness(1.08) contrast(0.95);
}

/* ---- Logo ---- */

.logo {
  width: 72px;
  height: auto;
  border-radius: 14px;
  margin-bottom: 2rem;
}

/* ---- Typography ---- */

.name {
  font-family: 'Plus Jakarta Sans', var(--font-family);
  font-size: 2.3rem;
  font-weight: 600;
  letter-spacing: -0.035em;
  line-height: 1.1;
  color: var(--color-text);
  margin-bottom: 0.45rem;
}

.role {
  font-size: 0.9rem;
  font-weight: 400;
  color: var(--color-text-secondary);
  letter-spacing: 0.015em;
  margin-bottom: 1.5rem;
}

.headline {
  font-size: 1.3rem;
  font-weight: 500;
  line-height: 1.5;
  color: var(--color-text);
  margin-bottom: 1.25rem;
}

.services {
  font-size: 0.8rem;
  font-weight: 400;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--color-text-secondary);
  margin-bottom: 1.75rem;
}

.sep {
  margin: 0 0.25em;
  opacity: 0.4;
}

/* ---- Divider ---- */

.divider {
  border: none;
  width: 48px;
  height: 1px;
  background-color: var(--color-border);
  margin: 0 0 1.75rem;
}

/* ---- Contact note ---- */

.contact-note {
  font-size: 0.95rem;
  color: var(--color-text-secondary);
  margin-bottom: 1.5rem;
}

/* ---- Action buttons ---- */

.actions {
  display: flex;
  margin-bottom: 2rem;
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  text-decoration: none;
  font-family: var(--font-family);
  font-size: 0.85rem;
  font-weight: 500;
  letter-spacing: 0.02em;
  border-radius: 9px;
  padding: 0.8rem 2.5rem;
  transition: background-color 0.25s ease, box-shadow 0.25s ease, transform 0.1s ease;
}

.btn-primary {
  background-color: var(--color-blue);
  color: var(--color-white);
  box-shadow: 0 1px 3px rgba(74, 159, 229, 0.15);
}

.btn-primary:hover {
  background-color: var(--color-blue-hover);
  box-shadow: 0 2px 8px rgba(74, 159, 229, 0.2);
}

.btn-primary:active {
  transform: scale(0.985);
}

/* ---- Competences ---- */

.competences {
  display: flex;
  gap: 1.5rem;
  margin-bottom: 1.75rem;
}

.competence {
  flex: none;
}

.competence-label {
  font-size: 0.75rem;
  font-weight: 500;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: var(--color-text-secondary);
  opacity: 0.55;
  cursor: pointer;
  list-style: none;
  transition: opacity 0.2s ease;
  user-select: none;
}

.competence-label::-webkit-details-marker {
  display: none;
}

.competence-label::marker {
  content: '';
}

.competence-label:hover {
  opacity: 0.8;
}

.competence[open] .competence-label {
  opacity: 0.75;
}

.competence-detail {
  font-size: 0.725rem;
  color: var(--color-text-secondary);
  opacity: 0.5;
  letter-spacing: 0.01em;
  line-height: 1.5;
  margin-top: 0.3rem;
  animation: competence-fade 0.25s ease;
}

@keyframes competence-fade {
  from { opacity: 0; transform: translateY(-2px); }
  to   { opacity: 1; transform: translateY(0); }
}

/* ---- Meta + social ---- */

.meta {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  font-size: 0.775rem;
  color: var(--color-text-secondary);
  opacity: 0.58;
  letter-spacing: 0.01em;
}

.social-link {
  display: inline-flex;
  align-items: center;
  color: currentColor;
  text-decoration: none;
  transition: opacity 0.2s ease;
}

.social-link:hover {
  opacity: 0.7;
}

.social-icon {
  display: block;
}

/* ---- Footer ---- */

.footer {
  margin-top: auto;
}

.footer-rule {
  width: 32px;
  height: 1px;
  background-color: rgba(228, 231, 235, 0.7);
  margin-bottom: 1rem;
}

.footer-content {
  display: flex;
  align-items: baseline;
  gap: 1rem;
}

.footer-copy {
  font-size: 0.725rem;
  color: var(--color-text-secondary);
  opacity: 0.5;
  letter-spacing: 0.01em;
}

.footer-nav a {
  font-size: 0.725rem;
  color: var(--color-text-secondary);
  opacity: 0.45;
  text-decoration: none;
  transition: opacity 0.2s ease;
}

.footer-nav a:hover {
  opacity: 0.75;
}

.footer-sep {
  margin: 0 0.3rem;
  color: var(--color-text-secondary);
  opacity: 0.3;
  font-size: 0.725rem;
}

/* ---- Legal pages ---- */

.page-legal {
  max-width: 640px;
  margin: 0 auto;
  padding: 4rem 2rem 3rem;
}

.page-legal .back-link {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  font-size: 0.8rem;
  color: var(--color-text-secondary);
  text-decoration: none;
  letter-spacing: 0.01em;
  margin-bottom: 3rem;
  transition: color 0.2s ease;
}

.page-legal .back-link:hover {
  color: var(--color-blue);
}

.page-legal .back-arrow {
  font-size: 1rem;
  line-height: 1;
}

.page-legal h1 {
  font-family: 'Plus Jakarta Sans', var(--font-family);
  font-size: 1.75rem;
  font-weight: 600;
  letter-spacing: -0.03em;
  line-height: 1.2;
  color: var(--color-text);
  margin-bottom: 0.5rem;
}

.page-legal .legal-subtitle {
  font-size: 0.85rem;
  color: var(--color-text-secondary);
  margin-bottom: 2.5rem;
}

.page-legal h2 {
  font-size: 1rem;
  font-weight: 600;
  color: var(--color-text);
  margin-top: 2.25rem;
  margin-bottom: 0.75rem;
}

.page-legal p,
.page-legal address {
  font-size: 0.9rem;
  line-height: 1.7;
  color: var(--color-text-secondary);
  margin-bottom: 0.75rem;
  font-style: normal;
}

.page-legal a {
  color: var(--color-blue);
  text-decoration: none;
  transition: color 0.2s ease;
}

.page-legal a:hover {
  color: var(--color-blue-hover);
}

.page-legal .footer-nav a {
  color: var(--color-text-secondary);
  opacity: 0.45;
  transition: opacity 0.2s ease;
}

.page-legal .footer-nav a:hover {
  color: var(--color-text-secondary);
  opacity: 0.75;
}

.page-legal .legal-divider {
  display: none;
}

.page-legal .footer {
  margin-top: 3rem;
}

.page-legal .footer-rule {
  width: 40px;
}

/* ---- Responsive ---- */

@media (max-width: 768px) {
  .layout {
    grid-template-columns: 1fr;
    grid-template-rows: 280px 1fr;
    height: auto;
    overflow: visible;
    min-height: 100vh;
  }

  .visual {
    order: -1;
    margin: 0;
    border-radius: 0;
  }

  .visual-img {
    object-position: center 40%;
  }

  .content {
    padding: 2.5rem 1.5rem 2rem;
    align-items: center;
    text-align: center;
  }

  .content-inner {
    max-width: 520px;
    display: flex;
    flex-direction: column;
    align-items: center;
  }

  .divider {
    margin-left: auto;
    margin-right: auto;
  }

  .competences {
    justify-content: center;
  }

  .competence-detail {
    text-align: center;
  }

  .actions {
    justify-content: center;
  }

  .meta {
    flex-direction: column;
    align-items: center;
    gap: 0.5rem;
  }

  .footer-rule {
    margin-left: auto;
    margin-right: auto;
  }

  .footer-content {
    justify-content: center;
  }
}

@media (max-width: 480px) {
  .layout {
    grid-template-rows: 220px 1fr;
  }

  .content {
    padding: 2rem 1.25rem 1.5rem;
  }

  .logo {
    width: 60px;
    border-radius: 12px;
    margin-bottom: 1.5rem;
  }

  .name {
    font-size: 1.55rem;
  }

  .role {
    margin-bottom: 1.5rem;
  }

  .headline {
    font-size: 1rem;
  }

  .btn {
    width: 100%;
    padding: 0.8rem 1.5rem;
  }
}

/* ---- Focus states for accessibility ---- */

.btn:focus-visible,
.social-link:focus-visible,
.footer-nav a:focus-visible {
  outline: 2px solid var(--color-blue);
  outline-offset: 2px;
}