/* ===== RESET ===== */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

/* ===== VARIABLES ===== */
:root {
  --bg:      #E8DFD0;
  --black:   #1F1F1F;
  --vert:    #4e7530;
  --rouge:   #D94F2B;
  --bleu:    #0C359C;

  --font-serif: 'Source Serif 4', serif;
  --font-mono:  'Space Mono', monospace;

  --navbar-h:      64px;
  --aside-w:       128px;
  --mobile-bar-h:  36px;
}

/* ===== BASE ===== */
html, body {
  height: 100%;
}

body {
  font-family: var(--font-mono);
  font-size: 12px;
  background-color: var(--bg);
  color: var(--black);
  display: flex;
  flex-direction: column;
}

h1, h2, h3, h4, h5, h6 {
  font-family: var(--font-serif);
}

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

/* ===== NAVBAR ===== */
.navbar {
  height: var(--navbar-h);
  background-color: var(--black);
  color: var(--bg);
  padding: 0 1.25rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.navbar div {
  display: flex;
  align-items: center;
  gap: 0.75rem;
}

.navbar p,
.navbar a {
  font-family: var(--font-mono);
  font-size: 0.8rem;
  letter-spacing: 0.05em;
  color: var(--bg);
}

.navbar .item-live {
  display: none;
  color: var(--rouge);
  font-weight: 700;
}

/* ===== LAYOUT ===== */
.corp {
  display: flex;
  flex-direction: column;       /* mobile : empilé */
  min-height: calc(100vh - var(--navbar-h));
}

.conteneur {
  flex: 1;
  min-width: 0;
}

/* ===== SIDEBAR MOBILE — ticker ===== */
.sidebar-mobile {
  overflow: hidden;
  height: var(--mobile-bar-h);
  flex-shrink: 0;
  border-bottom: 1px solid var(--black);
  display: flex;
  align-items: center;
}

.ticker-track {
  display: inline-flex;
  align-items: center;
  gap: 1.5rem;
  white-space: nowrap;
  animation: ticker 18s linear infinite;
}

.ticker-track span {
  font-size: 1rem;
  letter-spacing: 0.08em;
}

.ticker-sep {
  opacity: 0.4;
}

@keyframes ticker {
  from { transform: translateX(0); }
  to   { transform: translateX(-50%); }
}

/* ===== ASIDE (desktop uniquement) ===== */
aside {
  display: none;
}

/* ===== DESKTOP ===== */
@media (min-width: 1200px) {
  .navbar .item-live { display: block; }

  .corp {
    flex-direction: row;
    height: calc(100vh - var(--navbar-h));
    overflow: hidden;
  }

  .conteneur {
    display: flex;
    flex-direction: column;
    overflow: hidden;
    gap: 1rem;
  }

  .sidebar-mobile {
    display: none;
  }

  aside {
    display: flex;
    position: sticky;
    top: 0;
    width: var(--aside-w);
    flex-shrink: 0;
    height: calc(100vh - var(--navbar-h));
    overflow: visible;
    border-right: 1px solid var(--black);
    flex-direction: column;
    align-items: center;
    gap: 1rem;
    padding: 1rem 0.75rem;
  }

  .sun {
    width: 100%;
    max-width: 80px;
  }

  .croix {
    width: 40px;
    height: 40px;
    flex-shrink: 0;
  }

  .aside-text {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 2px;
    font-size: 0.7rem;
    letter-spacing: 0.06em;
    text-align: center;
    line-height: 1.4;
  }

  .trait {
    flex: 1;
    width: 1px;
    position: relative;
    background-image: repeating-linear-gradient(
      to bottom,
      var(--black) 0px,
      var(--black) 6px,
      transparent 6px,
      transparent 12px
    );
  }

  .scroll-dot {
    position: absolute;
    left: 50%;
    transform: translateX(-50%);
    top: 0;
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background-color: var(--black);
    transition: top 0.4s cubic-bezier(0.34, 1.56, 0.64, 1); /* géré dynamiquement par scroll-dot.js */
  }

  .aside-block {
    width: 100%;
  }

  .aside-block > div {
    width: 158px;
    clip-path: polygon(0 0, calc(100% - 20px) 0, 100% 20px, 100% 100%, 0 100%);
    background-color: var(--black);
    color: var(--bg);
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    padding: 1rem 0.75rem 1rem 1.25rem;
    gap: 2px;
  }

  .aside-block p:nth-child(odd)  { font-size: 0.65rem; letter-spacing: 0.06em; opacity: 0.7; }
  .aside-block p:nth-child(even) { font-size: 1.1rem; }

  .aside-log {
    margin-top: auto;
    align-items: flex-start;
    padding-bottom: 0.5rem;
  }
}
