/*
Theme Name: YTA Theme
Description: A custom WordPress theme for YTA App
Author: Dennis Filonoff
Version: 1.0
*/

/* CSS Custom Properties - YTA.app Color Scheme */
:root {
  /* Primary Colors - Update these based on yta.app */
  --primary-color: #3498db;
  --primary-dark: #2980b9;
  --secondary-color: #2c3e50;
  --accent-color: #e74c3c;

  /* Background Colors */
  --background-primary: #f8f9fa;
  --background-secondary: #ffffff;
  --background-dark: #2c3e50;

  /* Text Colors */
  --text-primary: #333333;
  --text-secondary: #666666;
  --text-light: #ecf0f1;
  --text-muted: #999999;

  /* Success/Error Colors */
  --success-color: #27ae60;
  --error-color: #e74c3c;
  --warning-color: #f39c12;
}

/* Reset and Base Styles */
*,
*::before,
*::after {
  box-sizing: border-box;
}

html {
  font-size: 16px;
  scroll-behavior: smooth;
}

body {
  font-family: 'Poppins', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, Cantarell, sans-serif;
  margin: 0;
  padding: 0;
  line-height: 1.6;
  color: var(--text-primary);
  background-color: var(--background-primary);
}

/* Global link styles */
a {
  color: var(--primary-color);
  text-decoration: none;
  transition: color 0.3s ease;
}

a:hover {
  color: var(--primary-dark);
  text-decoration: underline;
}

/* Global heading styles */
h2 {
  font-size: 1.5rem;
  font-weight: 700;
  color: #3c6987;
  margin: 3rem 0 1.5rem;
  line-height: 1.2;
  letter-spacing: -0.02em;
}

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

/* Sticky footer - simple min-height approach */
body > .container {
  min-height: calc(100vh - 120px); /* Approximate header + footer height */
}

.site-content {
  display: grid;
  grid-template-columns: 1fr 300px;
  gap: 2rem;
  margin-top: 2rem;
}

/* Header */
.site-header {
  padding: 1rem 0;
  position: sticky;
  top: 0;
  z-index: 100;
  background-color: var(--background-secondary);
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
}

.header-container {
  display: flex;
  justify-content: space-between;
  align-items: center;
}

/* Mobile menu toggle button - hidden on desktop */
.mobile-menu-toggle {
  display: none !important;
  flex-direction: column;
  justify-content: space-around;
  width: 30px;
  height: 30px;
  background: transparent;
  border: none;
  cursor: pointer;
  padding: 0;
  z-index: 1001;
}

.hamburger-line {
  width: 25px;
  height: 3px;
  background-color: var(--text-primary);
  transition: all 0.3s ease;
  transform-origin: 1px;
}

/* Hamburger animation when active */
.mobile-menu-toggle.active .hamburger-line:nth-child(1) {
  transform: rotate(45deg);
}

.mobile-menu-toggle.active .hamburger-line:nth-child(2) {
  opacity: 0;
  transform: translateX(20px);
}

.mobile-menu-toggle.active .hamburger-line:nth-child(3) {
  transform: rotate(-45deg);
}

.logo {
  display: flex;
  align-items: center;
}

.logo-img {
  height: 50px;
  width: auto;
  transition: transform 0.3s ease;
}

.logo-img:hover {
  transform: scale(1.05);
}

.header-nav {
  display: flex;
  gap: 2rem;
  align-items: center;
}

.primary-menu {
  display: flex;
  list-style: none;
  margin: 0;
  padding: 0;
  gap: 1.5rem;
}

.primary-menu li {
  margin: 0;
}

.primary-menu a {
  color: var(--text-primary);
  text-decoration: none;
  font-weight: 500;
  padding: 0.5rem 1rem;
  border-radius: 4px;
  transition: all 0.3s ease;
  position: relative;
}

.primary-menu a:hover {
  color: var(--primary-color);
  background-color: rgba(52, 152, 219, 0.1);
  text-decoration: none;
}

.primary-menu .current-menu-item > a,
.primary-menu .current_page_item > a {
  color: var(--primary-color);
  font-weight: 600;
}

.header-buttons {
  display: flex;
  gap: 1rem;
  align-items: center;
}

.nav-button {
  padding: 0.75rem 1.5rem;
  text-decoration: none;
  font-weight: 600;
  border-radius: 6px;
  transition: all 0.3s ease;
  display: inline-block;
  text-align: center;
  font-size: 0.95rem;
}

.nav-button-primary {
  background-color: var(--primary-color);
  color: white;
  border: 2px solid var(--primary-color);
}

.nav-button-primary:hover {
  background-color: var(--primary-dark);
  border-color: var(--primary-dark);
  transform: translateY(-1px);
  color: white !important;
  text-decoration: none !important;
}

.nav-button-secondary {
  background-color: transparent;
  color: var(--primary-color);
  border: 2px solid var(--primary-color);
}

.nav-button-secondary:hover {
  background-color: var(--primary-color);
  color: white;
  transform: translateY(-1px);
}

/* Main Content */
main {
  padding: 2rem;
}

/* Posts and Articles */
article {
  margin-bottom: 2rem;
  padding-bottom: 2rem;
}

article:last-child {
  margin-bottom: 0;
}

.entry-title {
  color: var(--secondary-color);
  margin: 0 0 1rem;
  font-size: 1.8rem;
  line-height: 1.3;
}

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

.entry-title a:hover {
  color: var(--primary-color);
}

.entry-meta {
  color: var(--text-secondary);
  font-size: 0.9rem;
  margin-bottom: 1rem;
}

.entry-meta a {
  color: var(--primary-color);
  text-decoration: none;
}

.entry-meta a:hover {
  text-decoration: underline;
}

.entry-content {
  margin: 1.5rem 0;
}

.entry-content p {
  margin-bottom: 1rem;
}

.entry-content h2 {
  font-size: 1.5rem;
  font-weight: 700;
  color: #3c6987;
  margin: 3rem 0 1.5rem;
  line-height: 1.2;
  letter-spacing: -0.02em;
}

.entry-content h3,
.entry-content h4 {
  margin: 2rem 0 1rem;
  color: var(--secondary-color);
}

.entry-content img {
  max-width: 100%;
  height: auto;
}

/* Post Thumbnails */
.post-thumbnail {
  margin-bottom: 1.5rem;
}

.post-thumbnail img {
  width: 100%;
  height: auto;
}

/* Sidebar */
.widget-area {
  padding: 0;
  height: fit-content;
}

.widget {
  background-color: var(--background-secondary);
  border: 1px solid #e1e5e9;
  border-radius: 8px;
  padding: 1.5rem;
  margin-bottom: 1.5rem;
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.05);
  transition: box-shadow 0.3s ease;
}

.widget:hover {
  box-shadow: 0 4px 8px rgba(0, 0, 0, 0.1);
}

.widget:last-child {
  margin-bottom: 0;
}

.widget-title {
  color: var(--secondary-color);
  margin: 0 0 1rem;
  font-size: 1.1rem;
  font-weight: 600;
  padding-bottom: 0.75rem;
  border-bottom: 2px solid var(--primary-color);
  position: relative;
}

.widget-title::after {
  content: '';
  position: absolute;
  bottom: -2px;
  left: 0;
  width: 30px;
  height: 2px;
  background-color: var(--accent-color);
}

.widget ul {
  list-style: none;
  padding: 0;
  margin: 0;
}

.widget li {
  padding: 0.75rem 0;
  border-bottom: 1px solid #f1f3f4;
  transition: all 0.3s ease;
}

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

.widget li:hover {
  padding-left: 0.5rem;
  background-color: #f8f9fa;
  border-radius: 4px;
}

.widget a {
  color: var(--text-primary);
  text-decoration: none;
  font-weight: 500;
  display: block;
  transition: color 0.3s ease;
}

.widget a:hover {
  color: var(--primary-color);
  text-decoration: none;
}

/* Widget specific styles */
.widget_search .search-form {
  display: flex;
  gap: 0.5rem;
  align-items: center;
}

.widget_search input[type='search'] {
  flex: 1;
  padding: 0.5rem 0.75rem;
  border: 1px solid #ddd;
  border-radius: 4px;
  font-size: 0.85rem;
  background-color: #fff;
  transition: border-color 0.3s ease;
}

.widget_search input[type='search']:focus {
  outline: none;
  border-color: var(--primary-color);
  box-shadow: 0 0 0 2px rgba(52, 152, 219, 0.1);
}

.widget_search input[type='submit'] {
  padding: 0.5rem 0.75rem;
  background-color: var(--primary-color);
  color: white;
  border: none;
  border-radius: 4px;
  cursor: pointer;
  font-size: 0.8rem;
  font-weight: 500;
  min-width: auto;
  white-space: nowrap;
  transition: all 0.3s ease;
}

.widget_search input[type='submit']:hover {
  background-color: var(--primary-dark);
  transform: translateY(-1px);
}

.widget_tag_cloud .tagcloud a {
  display: inline-block;
  background-color: #f1f3f4;
  color: var(--text-secondary);
  padding: 0.25rem 0.75rem;
  margin: 0.25rem;
  border-radius: 15px;
  font-size: 0.85rem !important;
  text-decoration: none;
  transition: all 0.3s ease;
}

.widget_tag_cloud .tagcloud a:hover {
  background-color: var(--primary-color);
  color: white;
  transform: translateY(-1px);
}

.widget_recent_comments li,
.widget_recent_entries li {
  padding: 1rem;
  background-color: #f8f9fa;
  margin-bottom: 0.75rem;
  border-radius: 6px;
  border: none;
}

.widget_recent_comments li:hover,
.widget_recent_entries li:hover {
  background-color: #e9ecef;
  padding-left: 1rem;
}

/* Navigation */
.nav-links {
  display: flex;
  justify-content: space-between;
  margin: 2rem 0;
}

.nav-links a {
  background: var(--primary-color);
  color: white;
  padding: 0.75rem 1.5rem;
  text-decoration: none;
  transition: background 0.3s ease;
}

.nav-links a:hover {
  background: var(--primary-dark);
}

/* Pagination */
.pagination {
  text-align: center;
  margin: 2rem 0;
}

.page-numbers {
  display: inline-block;
  padding: 0.5rem 1rem;
  margin: 0 0.25rem;
  text-decoration: none;
  color: var(--text-primary);
}

.page-numbers.current,
.page-numbers:hover {
  background: var(--primary-color);
  color: white;
}

/* Footer */
.site-footer {
  color: var(--text-primary);
  padding: 3rem 0 2rem;
  background-color: var(--background-secondary);
  border-top: 1px solid #e1e5e9;
}

.footer-content {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 2rem;
}

.footer-navigation {
  width: 100%;
  display: flex;
  justify-content: center;
}

.footer-menu {
  display: flex;
  list-style: none;
  margin: 0;
  padding: 0;
  gap: 2rem;
  flex-wrap: wrap;
  justify-content: center;
}

.footer-menu li {
  margin: 0;
}

.footer-menu a {
  color: var(--text-secondary);
  text-decoration: none;
  font-weight: 500;
  padding: 0.5rem 1rem;
  border-radius: 4px;
  transition: all 0.3s ease;
}

.footer-menu a:hover {
  color: var(--primary-color);
  background-color: rgba(52, 152, 219, 0.1);
  text-decoration: none;
}

.footer-info {
  text-align: center;
}

.footer-info p {
  margin: 0;
  color: var(--text-muted);
  font-size: 0.9rem;
}

/* Forms */
input[type='text'],
input[type='email'],
input[type='url'],
input[type='search'],
textarea {
  width: 100%;
  padding: 0.75rem;
  font-size: 1rem;
}

input:focus,
textarea:focus {
  outline: none;
}

button,
input[type='submit'] {
  background: var(--primary-color);
  color: white;
  padding: 0.75rem 1.5rem;
  cursor: pointer;
  font-size: 1rem;
  transition: background 0.3s ease;
}

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

/* Comments */
.comments-area {
  margin-top: 3rem;
  padding-top: 2rem;
}

.comment {
  margin-bottom: 2rem;
  padding: 1.5rem;
}

.comment-meta {
  margin-bottom: 1rem;
  color: var(--text-secondary);
  font-size: 0.9rem;
}

.comment-content {
  margin-bottom: 1rem;
}

/* Utility Classes */
.read-more {
  display: inline-block;
  color: var(--primary-color);
  text-decoration: none;
  font-weight: 600;
  margin-top: 1rem;
}

.read-more:hover {
  text-decoration: underline;
}

.screen-reader-text {
  position: absolute !important;
  clip: rect(1px, 1px, 1px, 1px);
  width: 1px;
  height: 1px;
  overflow: hidden;
}

/* Full Width Page Layout */
.site-content-fullwidth {
  margin-top: 2rem;
}

.main-fullwidth {
  padding: 3rem;
  max-width: 100%;
}

.page-fullwidth {
  margin-bottom: 0;
  padding-bottom: 0;
}

.entry-content-fullwidth {
  font-size: 1.1rem;
  line-height: 1.7;
}

.entry-content-fullwidth h1,
.entry-content-fullwidth h2,
.entry-content-fullwidth h3,
.entry-content-fullwidth h4,
.entry-content-fullwidth h5,
.entry-content-fullwidth h6 {
  margin: 2.5rem 0 1.5rem;
  color: var(--secondary-color);
}

.entry-content-fullwidth h1 {
  font-size: 2.5rem;
}

.entry-content-fullwidth h2 {
  font-size: 2rem;
}

.entry-content-fullwidth h3 {
  font-size: 1.5rem;
}

.entry-content-fullwidth p {
  margin-bottom: 1.5rem;
}

.entry-content-fullwidth img {
  max-width: 100%;
  height: auto;
  margin: 2rem 0;
}

.entry-content-fullwidth blockquote {
  margin: 2rem 0;
  padding: 1.5rem 2rem;
  font-style: italic;
  font-size: 1.1rem;
}

.entry-content-fullwidth ul,
.entry-content-fullwidth ol {
  margin: 1.5rem 0;
  padding-left: 2rem;
}

.entry-content-fullwidth li {
  margin-bottom: 0.5rem;
}

.post-thumbnail-fullwidth {
  margin-bottom: 2rem;
  text-align: center;
}

.post-thumbnail-fullwidth img {
  max-width: 100%;
  height: auto;
}

.comments-fullwidth {
  margin-top: 3rem;
  padding-top: 2rem;
}

.page-links {
  margin: 2rem 0;
  text-align: center;
}

.page-links .page-number {
  display: inline-block;
  padding: 0.5rem 1rem;
  margin: 0 0.25rem;
  background: var(--primary-color);
  color: white;
  text-decoration: none;
  font-weight: 600;
}

.edit-link {
  display: inline-block;
  margin-top: 2rem;
  padding: 0.5rem 1rem;
  background: var(--text-muted);
  color: white;
  text-decoration: none;
  font-size: 0.9rem;
}

.edit-link:hover {
  background: var(--text-secondary);
}

/* Responsive Design */
@media (max-width: 768px) {
  .site-content {
    grid-template-columns: 1fr;
    gap: 1rem;
  }

  .main-fullwidth {
    padding: 2rem 1.5rem;
  }

  .entry-content-fullwidth {
    font-size: 1rem;
  }

  .entry-content-fullwidth h1 {
    font-size: 2rem;
  }

  .entry-content-fullwidth h2 {
    font-size: 1.7rem;
  }

  .entry-content-fullwidth h3 {
    font-size: 1.3rem;
  }

  .container {
    padding: 0 15px;
  }

  main {
    padding: 1.5rem;
  }

  /* Show hamburger button on mobile */
  .mobile-menu-toggle {
    display: flex !important;
  }

  .header-container {
    padding: 1rem 0;
  }

  .logo-img {
    height: 40px;
  }

  /* Hide desktop navigation on mobile */
  .header-nav {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100vh;
    background-color: rgba(255, 255, 255, 0.98);
    backdrop-filter: blur(10px);
    flex-direction: column;
    justify-content: center;
    align-items: center;
    gap: 2rem;
    transform: translateY(-100%);
    transition: transform 0.3s ease;
    z-index: 1000;
    padding: 2rem;
  }

  /* Show mobile menu when active */
  .header-nav.active {
    transform: translateY(0);
  }

  .primary-menu {
    flex-direction: column;
    gap: 1rem;
    width: 100%;
    max-width: 300px;
    text-align: center;
    list-style: none;
    margin: 0;
    padding: 0;
  }

  .primary-menu li {
    margin: 0;
  }

  .primary-menu a {
    display: block;
    padding: 1rem 1.5rem;
    color: var(--text-primary);
    text-decoration: none;
    font-weight: 600;
    font-size: 1.1rem;
    border-radius: 8px;
    transition: all 0.3s ease;
    background-color: rgba(248, 249, 250, 0.5);
  }

  .primary-menu a:hover {
    background-color: var(--primary-color);
    color: white;
    transform: translateY(-2px);
  }

  .header-buttons {
    flex-direction: column;
    gap: 1rem;
    width: 100%;
    max-width: 300px;
  }

  .nav-button {
    width: 100%;
    padding: 1rem 1.5rem;
    font-size: 1rem;
    font-weight: 600;
    border-radius: 8px;
    text-align: center;
    transition: all 0.3s ease;
  }

  .nav-button:hover {
    transform: translateY(-2px);
  }

  .entry-title {
    font-size: 1.5rem;
  }

  h2,
  .entry-content h2 {
    font-size: 1.25rem;
    margin: 2rem 0 1rem;
  }

  .nav-links {
    flex-direction: column;
    gap: 1rem;
  }

  .nav-links a {
    text-align: center;
  }

  .footer-menu {
    flex-direction: column;
    gap: 1rem;
    text-align: center;
  }

  .footer-menu a {
    padding: 0.75rem 1rem;
    display: block;
  }

  .footer-content {
    gap: 1.5rem;
  }

  /* Mobile sidebar improvements */
  .widget {
    margin-bottom: 1rem;
    padding: 1rem;
  }

  .widget-title {
    font-size: 1rem;
    margin-bottom: 0.75rem;
  }

  .widget li {
    padding: 0.5rem 0;
  }

  .widget li:hover {
    padding-left: 0.25rem;
  }

  .widget_search .search-form {
    flex-direction: row;
    gap: 0.5rem;
    align-items: stretch;
  }

  .widget_search input[type='search'] {
    flex: 1;
    min-width: 0;
  }

  .widget_search input[type='submit'] {
    flex-shrink: 0;
    padding: 0.5rem 0.75rem;
  }
}
