/* ==========================================================================
   Ines.cz — stylesheet
   ========================================================================== */

:root {
  --text-color: #000000;
  --secondary-text: #444444;
  --border-color: #eeeeee;
  --accent-color: rgb(50 120 138);
  --font-mono: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, "Liberation Mono", "Courier New", monospace;
  --page-width: 1440px;     /* outer bound of .container, also the blog-list exception */
  --content-width: 800px;   /* default reading column inside .content */
}

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

html {
  min-height: 100%;
  interpolate-size: allow-keywords;
}

body {
  font-family: var(--font-mono);
  font-size: 1rem;
  font-weight: 400;
  background: url(/fx/atari-bg4.gif);
  color: var(--text-color);
  line-height: 1.6;
  letter-spacing: 0px;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

body > main {
  flex: 1 0 auto;
}

h1, h2, h3, h4, h5, h6 {
  font-weight: 700;
  letter-spacing: -0.5px;
}

a {
  color: inherit;
  text-decoration: none;
  transition: opacity 0.2s ease;
}

a:hover {
  text-decoration: underline;
}

ul {
  list-style: none;
}

.desktop-only { display: block !important; }
.mobile-only { display: none !important; }


/* --- Layout: container / content --------------------------------------- */

.container {
  width: 100%;
  max-width: var(--page-width);
  margin: 0 auto;
  padding: 0 20px;
}

.content {
  max-width: var(--content-width);
  margin: 0 auto;
}

.content--wide {
  max-width: 1280px;
}

/* exception: blog list — content spans the full container (1440) */
.posts .content {
  max-width: none;
}


/* --- Header -------------------------------------------------------------- */

.site-header {
  padding: 0 40px;
  height: 64px;
  width: 100%;
  display: flex;
  align-items: center;
  background: transparent;
}

.site-header .container {
  max-width: none;
  margin: 0;
  padding: 0;
  display: flex;
  justify-content: space-between;
  align-items: center;
  width: 100%;
}

.logo-link {
  display: inline-flex;
  align-items: center;
  text-decoration: none;
}

.logo-link:hover {
  opacity: 0.7;
  text-decoration: none;
}

.logotype {
  font-family: var(--font-mono);
  font-size: 1em;
  font-weight: 700;
  letter-spacing: -0.5px;
  color: var(--text-color);
}

.logotype-inner {
  color: var(--accent-color);
}

.cursor {
  font-weight: 700;
  animation: blink 1s step-end infinite;
}

@keyframes blink {
  from, to { opacity: 1; }
  50% { opacity: 0; }
}

nav ul {
  display: flex;
  gap: 20px;
}

nav a {
  font-family: var(--font-mono);
  font-size: 1em;
  font-weight: 700;
  line-height: 1.8;
  color: var(--text-color);
  letter-spacing: -0.5px;
  padding: 4px 12px;
  transition: transform 0.1s ease;
}

nav a:hover {
  text-decoration: none;
  transform: translateY(-2px);
}


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

footer {
  margin-top: 120px;
  padding: 80px 0;
  border-top: 2px solid var(--text-color);
  background-color: #ffffff;
  flex-shrink: 0;
}

.copyright {
  font-family: var(--font-mono);
  font-size: 80%;
  font-weight: 300;
  color: var(--secondary-text);
  text-transform: lowercase;
  letter-spacing: 1px;
  text-align: center;
}


/* --- Hero (shared by home + about) --------------------------------------- */

.hero {
  width: 100%;
  font-size: 1em;
}

.hero .content {
  padding: 40px 0;
  display: flex;
  gap: 40px;
}

.hero-avatar {
  width: 96px;
  height: 96px;
  border-radius: 50%;
  object-fit: cover;
  flex-shrink: 0;
  display: block;
}

.about_tags {
  font-family: var(--font-mono);
  font-size: 0.75em;
  font-weight: 300;
  color: var(--secondary-text);
  margin-bottom: 12px;
  text-transform: lowercase;
  letter-spacing: 1px;
}

.about_name {
  font-family: var(--font-mono);
  font-size: 1rem;
  font-weight: 800;
  margin-bottom: 15px;
  padding-top: 6px;
  line-height: 1.3;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.about_perex {
  color: var(--secondary-text);
  line-height: 1.6;
}

.about_perex a {
  color: var(--accent-color);
  text-decoration: underline;
}

.about summary {
  padding: 16px 0;
  cursor: pointer;
}

.about summary::marker {
  font-size: 80%;
}

.about_more::details-content {
  overflow: hidden;
  opacity: 0;
  transform: translateY(-4px);
  block-size: 0;
  transition-property: opacity, transform, block-size, content-visibility;
  transition-duration: 0.28s;
  transition-timing-function: ease;
  transition-behavior: allow-discrete;
}

.about_more[open]::details-content {
  opacity: 1;
  transform: translateY(0);
  block-size: auto;
  block-size: calc-size(auto, size);
}

@starting-style {
  .about_more[open]::details-content {
    opacity: 0;
    transform: translateY(-4px);
    block-size: 0;
  }
}

.about_more-content a {
  color: var(--accent-color);
  text-decoration: underline;
}

.section-separator {
  font-family: var(--font-mono);
  font-size: 1em;
  font-weight: 700;
  text-align: center;
  padding: 0 20px;
  margin: 20px 0;
}


/* --- About: extra section (projects list) -------------------------------- */

.about_extra {
  margin-top: 40px;
}

.about_extra h4 {
  font-family: var(--font-mono);
  font-size: 1em;
  font-weight: 700;
  text-transform: lowercase;
  letter-spacing: 1px;
  margin-bottom: 12px;
}

.about_extra ul {
  padding-left: 20px;
  list-style-type: square;
}

.about_extra li {
  font-size: 1em;
  color: var(--secondary-text);
  line-height: 1.6;
  margin-bottom: 10px;
}

.about_extra li b a {
  color: var(--text-color);
  text-decoration: underline;
}


/* --- Blog grid (shared by home + blog list) ------------------------------ */

.blog-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 60px;
  margin: 40px 0 80px;
}

.blog-item a {
  width: 100%;
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  text-align: left;
  text-decoration: none;
}

.blog-item a:hover {
  text-decoration: none;
}

.blog-item a:hover .blog-item_headline {
  text-decoration: underline;
}

.blog-item .image-container {
  position: relative;
  width: 100%;
  padding-top: 56.25%;
  margin-bottom: 25px;
  border: 0;
  border-radius: 8px;
  overflow: hidden;
}

.blog-item .image-container img {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  border-radius: 8px;
  transition: opacity 0.3s ease, transform 0.3s ease;
}

.blog-item a:hover .image-container img {
  opacity: 0.9;
  transform: translateY(-5px);
}

.blog-item_tags {
  font-family: var(--font-mono);
  font-size: 0.75em;
  font-weight: 300;
  color: var(--secondary-text);
  margin-bottom: 12px;
  text-transform: lowercase;
  letter-spacing: 1px;
}

.blog-item_headline {
  font-family: var(--font-mono);
  font-size: 1rem;
  font-weight: 800;
  margin-bottom: 15px;
  line-height: 1.3;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.blog-item_perex {
  font-size: 1em;
  color: var(--secondary-text);
  line-height: 1.8;
  margin-bottom: 20px;
}

.read-more {
  align-self: flex-end;
  font-family: var(--font-mono);
  font-size: 1em;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 2px;
  border-bottom: 3px solid transparent;
  padding-bottom: 2px;
  transition: border-color 0.2s ease;
}

.blog-item a:hover .read-more {
  border-color: var(--accent-color);
}

.home-view-all {
  text-align: center;
  margin: 20px 0 80px;
}

.home-view-all a {
  font-family: var(--font-mono);
  font-size: 1em;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 2px;
  border-bottom: 3px solid var(--text-color);
  padding-bottom: 3px;
}


/* --- Projekty list page (/projekty/) --------------------------------------------- */

.pagination {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin: 40px 0 80px;
  font-family: var(--font-mono);
  font-size: 1em;
}

.pagination__prev,
.pagination__next {
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 1px;
  border-bottom: 3px solid transparent;
  padding-bottom: 2px;
  transition: border-color 0.2s ease;
}

.pagination__prev:hover,
.pagination__next:hover {
  text-decoration: none;
  border-color: var(--accent-color);
}

.pagination__info {
  color: var(--secondary-text);
}


/* --- Post detail ----------------------------------------------------------- */

.post-header {
  margin: 60px 0 40px;
  text-align: left;
}

.posts .post-header {
  text-align: center;
  padding-bottom: 32px;
}

.post-header_tags {
  font-family: var(--font-mono);
  color: var(--secondary-text);
  font-weight: 300;
  text-transform: lowercase;
  letter-spacing: 2px;
  margin-bottom: 15px;
  display: block;
  font-size: 0.75em;
}

.post-header_headline {
  font-family: arial;
  font-size: 4rem;
  font-weight: 400;
  line-height: 1.1;
  margin-bottom: 30px;
  letter-spacing: 6px;
}

.post-header_subtitle {
  font-family: var(--font-mono);
  font-weight: 700;
  color: var(--secondary-text);
  line-height: 1.6;
  letter-spacing: 0.5px;
}

.post-main-image {
  position: relative;
  width: 100%;
  padding-top: 42.85%;
  background-color: #f0f0f0;
  margin-bottom: 60px;
  overflow: hidden;
}

.post-main-image img {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.post-nav {
  text-align: right;
  margin-top: 40px;
}

/* article body typography */

.post-body {
  line-height: 1.8;
}

.post-body p {
  margin-bottom: 30px;
}

.post-body h2, .post-body h3 {
  font-family: var(--font-mono);
  text-transform: uppercase;
  margin: 60px 0 20px;
  line-height: 1.2;
}

.post-body blockquote {
  border-left: 4px solid var(--text-color);
  padding: 10px 0 10px 30px;
  margin: 40px 0;
  font-style: italic;
  color: var(--secondary-text);
}

.post-body ul {
  list-style: disc;
  margin: 30px 0 30px 30px;
}

.post-body ol {
  list-style: decimal;
  margin: 30px 0 30px 30px;
}

.post-body li {
  margin-bottom: 10px;
}

.post-body a {
  color: var(--accent-color);
  text-decoration: underline;
}

.post-body img {
  width: 100%;
  height: auto;
  margin: 40px 0 10px;
  display: block;
}

.image-caption {
  font-family: var(--font-mono);
  font-size: 1em;
  color: var(--secondary-text);
  text-align: center;
  margin-bottom: 40px;
  display: block;
  text-transform: uppercase;
}

.code-wrapper {
  margin: 40px 0;
  border: 1px solid var(--border-color);
}

.code-header {
  background-color: #fafafa;
  padding: 10px 20px;
  border-bottom: 1px solid var(--border-color);
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.code-lang {
  font-family: var(--font-mono);
  font-size: 1em;
  font-weight: 700;
  text-transform: uppercase;
  color: var(--secondary-text);
}

.code-description {
  font-family: var(--font-mono);
  font-size: 1em;
  color: #999;
}

.post-body pre {
  background-color: #fcfcfc;
  padding: 20px;
  overflow-x: auto;
}

.post-body code {
  font-family: var(--font-mono);
  font-size: 1em;
  line-height: 1.5;
}

.post-body p code {
  background-color: #e1e1e1;
  padding: 2px 6px;
  border-radius: 3px;
}


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

@media (max-width: 768px) {
  .site-header { padding: 0 20px; }
  nav ul { gap: 32px; }

  .hero .content { flex-direction: column; gap: 20px; }

  .blog-grid { grid-template-columns: 1fr; gap: 40px; }

  .post-header_headline { font-size: 2rem; letter-spacing: 0.5px; margin-bottom: 15px; }

  .code-header { flex-direction: column; align-items: flex-start; gap: 5px; padding: 15px 20px; }

  footer { padding: 40px 0; }
  .desktop-only { display: none !important; }
  .mobile-only { display: block !important; }
}

@media (max-width: 480px) {
  nav ul { gap: 32px; }
  .post-header_headline { font-size: 1.6rem; }
  .blog-item_headline { font-size: 1.1rem; }
}
