/* ========== UTILITY STYLES ========== */

/* line numbers */
.line-numbers {
  position: absolute;
  left: 0;
  top: 0;
  bottom: 0;
  width: 45px;
  background-color: #f0f0f0;
  border-right: 1px solid #e0e0e0;
  padding: 15px 5px;
  text-align: right;
  user-select: none;
  font-family: var(--font-mono);
  font-size: 14px;
  line-height: 1.5;
  color: #999;
  overflow: hidden;
  display: flex;
  flex-direction: column;
}

.line-numbers span {
  display: block;
  height: 1.5em;
  line-height: 1.5;
}

/* table styles */
table {
  border-collapse: collapse;
  width: 100%;
  margin-bottom: var(--space-lg);
}

table th,
table td {
  border: 1px solid var(--border);
  padding: var(--space-sm);
  text-align: left;
}

table th {
  background-color: var(--bg-secondary);
  font-weight: bold;
}

table tr:nth-child(even) {
  background-color: var(--bg-tertiary);
}

/* image styles */
img {
  max-width: 100%;
  height: auto;
  display: block;
}

figure {
  margin: var(--space-lg) 0;
}

figcaption {
  margin-top: var(--space-sm);
  text-align: center;
  font-size: 0.875rem;
  color: var(--text-tertiary);
}

/* form elements */
input[type="text"],
input[type="email"],
textarea {
  width: 100%;
  padding: var(--space-sm);
  border: 1px solid var(--border);
  border-radius: 0.375rem;
  font-family: var(--font-sans);
  font-size: 1rem;
  transition: border-color var(--transition);
}

input[type="text"]:focus,
input[type="email"]:focus,
textarea:focus {
  outline: none;
  border-color: var(--primary);
  box-shadow: 0 0 0 3px rgba(37, 99, 235, 0.1);
}

button[type="submit"] {
  padding: var(--space-sm) var(--space-lg);
  background: var(--primary);
  color: white;
  border: none;
  border-radius: 0.375rem;
  font-weight: 600;
  cursor: pointer;
  transition: background var(--transition);
}

button[type="submit"]:hover {
  background: var(--primary-dark);
}

/* print styles */
@media print {
  .site-header,
  .site-footer,
  .post-navigation,
  .post-share,
  .nav-menu,
  .copy-button {
    display: none !important;
  }
  
  body {
    font-size: 12pt;
    line-height: 1.5;
    color: black;
  }
  
  a {
    color: black;
    text-decoration: underline;
  }
  
  pre {
    white-space: pre-wrap;
    word-break: break-word;
  }
}