/*
Theme Name: Terminal Theme
Theme URI: https://github.com/francuzzz/blog
Author: Vladimir Deryabin
Author URI: https://deryab.in
Description: A modern terminal-style WordPress theme inspired by DevOps aesthetics. Features dark theme with CRT effects, monospace typography, and terminal-inspired UI elements.
Version: 1.0.0
License: GNU General Public License v2 or later
License URI: http://www.gnu.org/licenses/gpl-2.0.html
Text Domain: terminal-theme
Tags: dark, terminal, devops, monospace, modern, responsive
*/

:root {
  --bg-color: #0b0e14;
  --text-color: #e6edf3;
  --prompt-color: #79c0ff;
  --accent-color: #1f6feb;
  --border-color: #30363d;
  --header-bg: #161b22;
  --card-bg: rgba(22, 27, 34, 0.5);
  --font-main: 'Fira Code', monospace;
}

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

body {
  background-color: var(--bg-color);
  color: var(--text-color);
  font-family: var(--font-main);
  line-height: 1.6;
  min-height: 100vh;
  position: relative;
}

/* CRT Effect */
body::before {
  content: '';
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: linear-gradient(rgba(18, 16, 16, 0) 50%, rgba(0, 0, 0, 0.25) 50%), 
              linear-gradient(90deg, rgba(255, 0, 0, 0.06), rgba(0, 255, 0, 0.02), rgba(0, 0, 255, 0.06));
  background-size: 100% 2px, 3px 100%;
  pointer-events: none;
  opacity: 0.15;
  z-index: 1000;
}

/* Header */
.site-header {
  background-color: var(--header-bg);
  border-bottom: 1px solid var(--border-color);
  padding: 15px 0;
  position: sticky;
  top: 0;
  z-index: 100;
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.3);
}

.header-container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 20px;
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.site-title {
  color: var(--prompt-color);
  font-size: 1.2rem;
  font-weight: 600;
  text-decoration: none;
  display: flex;
  align-items: center;
  gap: 10px;
}

.terminal-dots {
  display: flex;
  gap: 6px;
}

.dot {
  width: 10px;
  height: 10px;
  border-radius: 50%;
}

.dot.red { background-color: #ff5f56; }
.dot.yellow { background-color: #ffbd2e; }
.dot.green { background-color: #27c93f; }

.main-navigation ul {
  list-style: none;
  display: flex;
  gap: 25px;
  flex-wrap: wrap;
}

.main-navigation li {
  margin: 0;
}

.main-navigation a {
  color: var(--text-color);
  text-decoration: none;
  font-size: 0.9rem;
  transition: color 0.3s ease;
  opacity: 0.8;
}

.main-navigation a:hover,
.main-navigation .current-menu-item a {
  color: var(--prompt-color);
  opacity: 1;
}

/* Container */
.site-container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 40px 20px;
}

/* Hero Section */
.hero-section {
  background: var(--card-bg);
  border: 1px solid var(--border-color);
  border-radius: 8px;
  padding: 40px;
  margin-bottom: 40px;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.3);
}

.hero-section h1 {
  color: var(--prompt-color);
  font-size: 2.5rem;
  margin-bottom: 15px;
  font-weight: 600;
}

.hero-section p {
  font-size: 1.1rem;
  opacity: 0.9;
  line-height: 1.8;
}

.prompt-line {
  color: var(--prompt-color);
  font-size: 0.9rem;
  margin-bottom: 10px;
}

/* Content Area */
.content-area {
  display: grid;
  grid-template-columns: 2fr 1fr;
  gap: 30px;
  margin-bottom: 40px;
}

@media (max-width: 768px) {
  .content-area {
    grid-template-columns: 1fr;
  }
}

/* Posts/Articles */
.posts-container {
  display: flex;
  flex-direction: column;
  gap: 25px;
}

.post-card,
article {
  background: var(--card-bg);
  border: 1px solid var(--border-color);
  border-left: 4px solid var(--accent-color);
  border-radius: 8px;
  padding: 25px;
  transition: transform 0.3s ease, box-shadow 0.3s ease;
  box-shadow: 0 5px 15px rgba(0, 0, 0, 0.2);
}

.post-card:hover,
article:hover {
  transform: translateY(-2px);
  box-shadow: 0 10px 25px rgba(31, 111, 235, 0.2);
}

.post-title,
.entry-title {
  color: var(--prompt-color);
  font-size: 1.5rem;
  margin-bottom: 10px;
  font-weight: 600;
}

.post-title a,
.entry-title a {
  color: inherit;
  text-decoration: none;
}

.post-title a:hover,
.entry-title a:hover {
  color: var(--accent-color);
}

.post-meta,
.entry-meta {
  font-size: 0.85rem;
  color: var(--text-color);
  opacity: 0.6;
  margin-bottom: 15px;
  display: flex;
  gap: 15px;
  flex-wrap: wrap;
}

.post-excerpt,
.entry-content {
  line-height: 1.8;
  opacity: 0.9;
  margin-bottom: 15px;
}

.read-more,
.more-link {
  color: var(--accent-color);
  text-decoration: none;
  font-size: 0.9rem;
  display: inline-block;
  transition: color 0.3s ease;
}

.read-more:hover,
.more-link:hover {
  color: var(--prompt-color);
  text-shadow: 0 0 5px var(--prompt-color);
}

/* Sidebar */
.sidebar {
  display: flex;
  flex-direction: column;
  gap: 25px;
}

.widget {
  background: var(--card-bg);
  border: 1px solid var(--border-color);
  border-radius: 8px;
  padding: 25px;
  box-shadow: 0 5px 15px rgba(0, 0, 0, 0.2);
}

.widget-title {
  color: var(--prompt-color);
  font-size: 1.2rem;
  margin-bottom: 15px;
  font-weight: 600;
  border-bottom: 1px solid var(--border-color);
  padding-bottom: 10px;
}

.widget ul {
  list-style: none;
}

.widget li {
  padding: 8px 0;
  border-bottom: 1px solid rgba(48, 54, 61, 0.5);
}

.widget li:last-child {
  border-bottom: none;
}

.widget a {
  color: var(--text-color);
  text-decoration: none;
  opacity: 0.8;
  transition: all 0.3s ease;
}

.widget a:hover {
  color: var(--accent-color);
  opacity: 1;
  padding-left: 5px;
}

/* Footer */
.site-footer {
  background-color: var(--header-bg);
  border-top: 1px solid var(--border-color);
  padding: 30px 0;
  margin-top: 60px;
  text-align: center;
  opacity: 0.8;
}

.footer-content {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 20px;
}

/* Code blocks */
code {
  background: rgba(0, 0, 0, 0.3);
  padding: 2px 6px;
  border-radius: 3px;
  color: var(--prompt-color);
  font-size: 0.9em;
}

pre {
  background: rgba(0, 0, 0, 0.3);
  border-left: 3px solid var(--accent-color);
  padding: 15px;
  border-radius: 4px;
  overflow-x: auto;
  margin: 15px 0;
}

pre code {
  background: transparent;
  padding: 0;
}

/* Buttons */
.btn,
.button,
input[type="submit"],
button {
  display: inline-block;
  padding: 10px 20px;
  background: var(--accent-color);
  color: white;
  text-decoration: none;
  border-radius: 4px;
  transition: all 0.3s ease;
  border: none;
  cursor: pointer;
  font-family: var(--font-main);
  font-size: 0.9rem;
}

.btn:hover,
.button:hover,
input[type="submit"]:hover,
button:hover {
  background: var(--prompt-color);
  box-shadow: 0 0 10px rgba(121, 192, 255, 0.5);
}

/* Terminal-like elements */
.terminal-line {
  color: var(--prompt-color);
  margin: 5px 0;
}

.terminal-line::before {
  content: '$ ';
  opacity: 0.7;
}

/* WordPress specific */
.wp-caption {
  max-width: 100%;
  margin: 15px 0;
}

.wp-caption-text {
  font-size: 0.85rem;
  opacity: 0.7;
  margin-top: 5px;
}

.alignleft {
  float: left;
  margin: 0 20px 20px 0;
}

.alignright {
  float: right;
  margin: 0 0 20px 20px;
}

.aligncenter {
  display: block;
  margin: 0 auto 20px;
}

/* Navigation */
.pagination {
  display: flex;
  gap: 10px;
  justify-content: center;
  margin: 40px 0;
}

.pagination a,
.pagination span {
  padding: 8px 15px;
  background: var(--card-bg);
  border: 1px solid var(--border-color);
  border-radius: 4px;
  color: var(--text-color);
  text-decoration: none;
  transition: all 0.3s ease;
}

.pagination a:hover,
.pagination .current {
  background: var(--accent-color);
  color: white;
  border-color: var(--accent-color);
}

/* Comments */
.comments-area {
  margin-top: 40px;
  padding-top: 40px;
  border-top: 1px solid var(--border-color);
}

.comment {
  background: var(--card-bg);
  border: 1px solid var(--border-color);
  border-radius: 8px;
  padding: 20px;
  margin-bottom: 20px;
}

.comment-author {
  color: var(--prompt-color);
  font-weight: 600;
  margin-bottom: 10px;
}

.comment-meta {
  font-size: 0.85rem;
  opacity: 0.6;
  margin-bottom: 10px;
}

/* Search */
.search-form {
  display: flex;
  gap: 10px;
}

.search-form input[type="search"] {
  flex: 1;
  background: rgba(0, 0, 0, 0.3);
  border: 1px solid var(--border-color);
  border-radius: 4px;
  padding: 10px;
  color: var(--text-color);
  font-family: var(--font-main);
}

.search-form input[type="search"]:focus {
  outline: none;
  border-color: var(--accent-color);
  box-shadow: 0 0 5px rgba(31, 111, 235, 0.3);
}
