/**
 * Theme Name: bootstrap one page
 * Bootstrap One Page - Optimized CSS
 * Theme URI: Raylewaydigital.com
 * Author: Coley Rayle
 * Version: 1.2
 * License: GNU GPL v2
 */
:root {
  --primary-color: #4CAF50;
  --secondary-color: #57130e;
  --text-color: #333;
  --light-bg: #f9f9f9;
  --white: #fff;
  --dark-bg: rgba(0,0,0,0.7);
  --shadow-sm: 0 2px 10px rgba(0,0,0,0.1);
  --shadow-md: 0 5px 15px rgba(0,0,0,0.1);
  --shadow-lg: 0 10px 20px rgba(0,0,0,0.1);
  --transition: all 0.3s ease;
  --navbar-bg: #ffffff;
}

body {
  font-family: 'Open Sans', sans-serif;
  color: var(--text-color);
  overflow-x: hidden;
  -webkit-text-size-adjust: 100%;
}

html {
  scroll-behavior: smooth;
}

body.wp-admin .custom-logo,
body.customize-preview .custom-logo {
  cursor: move;
  border: 2px dashed #007cba;
  padding: 4px;
}

/* ========================================================================== */
/* Header & Navigation - Updated Styles */
/* ========================================================================== */

/* Limit navbar menu width and align items to the right */
.navbar-nav {
  width: 250px; /* Adjust this as needed */
  justify-content: flex-end;
  margin-left: auto;
  margin-right: 0;
  text-align: right;
}

.navbar-nav .nav-link {
  color: #57130e !important; /* keep your brand color on light nav */
}

/* Toggler + icon */
.navbar-toggler {
  color: #57130e !important;
  border-color: rgba(87, 19, 14, 0.1);
}
.navbar-toggler-icon {
  background-image: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 30 30'%3e%3cpath stroke='rgba(87, 19, 14, 1)' stroke-linecap='round' stroke-miterlimit='10' stroke-width='2' d='M4 7h22M4 15h22M4 23h22'/%3e%3c/svg%3e");
}

/* NOTE: Bootstrap Collapse already animates height; using max-height conflicts on some devices. */
.navbar-collapse {
  /* max-height: 0;  */ /* ⛔ Commented: interferes with Bootstrap's height-based Collapse */
  /* overflow: hidden; */ /* ⛔ Commented: let Bootstrap manage */
  /* transition: max-height 0.3s ease-out; */ /* ⛔ Commented: duplicate animation */
  background-color: var(--navbar-bg);
  width: 100%;
}
.navbar-collapse.show {
  /* max-height: 500px; */ /* ⛔ Commented: let Bootstrap manage */
  /* transition: max-height 0.5s ease-in; */ /* ⛔ Commented */
}

.site-header {
  min-height: 70px;
  transition: none;
}

@media (min-width: 992px) {
  .navbar-collapse {
    /* max-height: none; */ /* ⛔ Redundant with Bootstrap; safe to remove */
    /* overflow: visible; */ /* ⛔ Redundant */
    background-color: transparent;
    width: auto;
  }

  .navbar-nav .nav-link {
    position: relative;
    padding: 0.5rem 1rem;
  }
  .navbar-nav .nav-link::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 50%;
    width: 0;
    height: 2px;
    background: #57130e;
    transition: all 0.3s ease;
  }
  .navbar-nav .nav-link:hover::after {
    width: 100%;
    left: 0;
  }
}

@media (min-width: 992px) {
  .ui-draggable-dragging .custom-logo { opacity: 0.8; }

  .ui-resizable-handle {
    background: var(--primary-color);
    width: 10px;
    height: 10px;
    position: absolute;
    z-index: 20;
    border-radius: 50%;
    opacity: 0;
    transition: opacity 0.2s ease;
  }
  .logo-container:hover .ui-resizable-handle { opacity: 1; }
  .ui-resizable-se { right: -5px; bottom: -5px; cursor: se-resize; }
  .ui-resizable-sw { left: -5px; bottom: -5px; cursor: sw-resize; }
  .ui-resizable-ne { right: -5px; top: -5px; cursor: ne-resize; }
  .ui-resizable-nw { left: -5px; top: -5px; cursor: nw-resize; }
}

/* ========================================================================== */
/* Hero Section */
/* ========================================================================== */
.hero-section {
  position: relative;
  min-height: 50vh;
  padding: 60px 15px 30px;
  overflow: hidden;
}
.hero-image-container {
  position: relative;
  width: 100%;
  max-width: 1200px;
  margin: 0 auto;
}
.hero-image {
  display: block;
  width: 100%;
  height: auto;
  max-height: 300px;
  margin: 0 auto;
  border-radius: 8px;
  box-shadow: var(--shadow-md);
  object-fit: contain;
  image-rendering: crisp-edges;
}

/* Countdown Timer */
.countdown-overlay {
  position: relative;
  background: var(--dark-bg);
  color: var(--secondary-color);
  padding: 20px;
  border-radius: 8px;
  width: 100%;
  margin: 20px auto;
  text-align: center;
}
.countdown-title {
  margin-bottom: 15px;
  font-size: 1.5rem;
  font-weight: 700;
  text-transform: uppercase;
  color: var(--white);
}
.countdown-timer {
  display: flex;
  justify-content: center;
  flex-wrap: wrap;
  gap: 10px;
}
.countdown-item {
  text-align: center;
  min-width: 60px;
  padding: 5px;
}
.countdown-number {
  font-size: 1.8rem;
  font-weight: bold;
  color: #ff0000 !important; /* Override to regular red */
  text-shadow: 0 0 5px rgba(255,0,0,0.5);
  margin-bottom: 5px;
  display: block;
}
.countdown-label {
  font-size: 0.8rem;
  text-transform: uppercase;
  color: var(--white);
  letter-spacing: 1px;
}

/* Ribbon */
.ribbon {
  position: absolute;
  top: 10px;
  right: 10px;
  width: 100px;
  height: 100px;
  overflow: hidden;
  z-index: 20;
}
.ribbon-content {
  position: absolute;
  display: block;
  width: 150px;
  padding: 10px 0;
  background-color: var(--secondary-color);
  box-shadow: var(--shadow-sm);
  color: var(--white);
  font-size: 14px;
  font-weight: bold;
  text-align: center;
  right: -25px;
  top: 30px;
  transform: rotate(45deg);
  text-transform: uppercase;
}

@media (min-width: 768px) {
  .hero-section { min-height: 70vh; padding: 80px 20px 40px; }
  .hero-image { max-height: 500px; }

  .countdown-overlay {
    position: absolute;
    top: 50%; left: 50%;
    transform: translate(-50%, -50%);
    width: 80%; max-width: 600px;
    padding: 30px 40px; margin: 0;
  }

  .countdown-title { font-size: 1.8rem; }
  .countdown-item { min-width: 80px; }
  .countdown-number { font-size: 3rem; }
  .countdown-label { font-size: 1rem; }

  .ribbon { width: 150px; height: 150px; }
  .ribbon-content { width: 225px; padding: 15px 0; font-size: 16px; }
}

/* ========================================================================== */
/* Content Sections */
/* ========================================================================== */
.section { padding: 50px 0; scroll-margin-top: 70px; }
.section-title { margin-bottom: 30px; text-align: center; font-size: 2rem; }

.post-card {
  margin-bottom: 20px;
  height: 100%;
  display: flex;
  flex-direction: column;
  transition: var(--transition);
  border: 1px solid rgba(0,0,0,0.1);
  border-radius: 8px;
  overflow: hidden;
}
.post-card:hover { transform: translateY(-5px); box-shadow: var(--shadow-lg); }
.post-card .card-img-top {
  height: 180px; width: 100%;
  object-fit: cover; background-color: #f5f5f5;
}
.post-card .card-body {
  flex: 1; display: flex; flex-direction: column; padding: 20px;
}
.post-card .card-title { font-size: 1.2rem; margin-bottom: 10px; }
.post-card .card-text { flex-grow: 1; margin-bottom: 15px; font-size: 0.95rem; }
.post-card .btn { align-self: flex-start; font-size: 0.9rem; padding: 8px 16px; }

@media (min-width: 768px) {
  .section { padding: 80px 0; scroll-margin-top: 80px; }
  .section-title { margin-bottom: 50px; font-size: 2.5rem; }
  .post-card .card-img-top { height: 200px; }
  .post-card .card-title { font-size: 1.3rem; }
  .post-card .btn { font-size: 1rem; padding: 10px 20px; }
}

/* ========================================================================== */
/* Modal Styles */
/* ========================================================================== */
.post-modal .modal-dialog { margin: 10px; max-width: calc(100% - 20px); }
.post-modal .modal-content { border-radius: 8px; overflow: hidden; }
.post-modal .modal-header { padding: 15px; border-bottom: 1px solid #eee; }
.post-modal .modal-body { padding: 20px; max-height: 70vh; overflow-y: auto; }

#postModalImage img {
  max-width: 100%; height: auto; display: block;
  margin: 0 auto 15px; border-radius: 5px;
}

.modal-title { font-size: 1.5rem; margin-bottom: 10px; }
#postMeta { margin-bottom: 15px; font-size: 0.9rem; }
#postModalContent { font-size: 1rem; line-height: 1.6; }
#postModalContent img { max-width: 100%; height: auto; margin: 15px 0; }

.modal-backdrop.show { opacity: 0.8; background-color: rgba(0, 0, 0, 0.4); }

@media (min-width: 768px) {
  .post-modal .modal-dialog { margin: 30px auto; max-width: 800px; }
  .post-modal .modal-header { padding: 20px; }
  .post-modal .modal-body { padding: 30px; max-height: 80vh; }
  #postModalImage img { max-height: 400px; margin-bottom: 20px; }
  .modal-title { font-size: 1.8rem; }
}

/* ========================================================================== */
/* Comments Section */
/* ========================================================================== */
.modal-comments-section { border-top: 1px solid #eee; padding-top: 20px; margin-top: 20px; }
.modal-comments-section h5 { font-size: 1.3rem; margin-bottom: 15px; }
.comments-list {
  max-height: 200px; overflow-y: auto; margin-bottom: 20px; padding: 10px;
  background: var(--light-bg); border-radius: 5px;
}
.comment {
  padding: 12px; background: var(--white); border-radius: 5px; margin-bottom: 10px;
  box-shadow: 0 1px 3px rgba(0,0,0,0.1);
}
.comment-author { margin-bottom: 5px; display: flex; align-items: center; font-size: 0.9rem; }
.comment-author strong { margin-right: 10px; }
.comment-content { font-size: 0.9rem; line-height: 1.5; }

/* ========================================================================== */
/* Comment Form */
/* ========================================================================== */
#commentform { margin-top: 20px; }
#commentform .form-group { margin-bottom: 15px; }
#commentform textarea { min-height: 100px; font-size: 0.9rem; }
#commentform input { font-size: 0.9rem; padding: 10px 15px; }
#commentform button { font-size: 0.9rem; padding: 10px 20px; }

/* ========================================================================== */
/* Contact Form */
/* ========================================================================== */
.contact-form .form-control {
  margin-bottom: 15px; padding: 12px 15px; font-size: 0.9rem;
  border-radius: 4px; border: 1px solid #ddd;
}
.contact-form textarea.form-control { min-height: 150px; }
.contact-form button[type="submit"] { width: 100%; padding: 12px; font-size: 1rem; }

@media (min-width: 768px) {
  .contact-form .form-control { margin-bottom: 20px; padding: 15px; font-size: 1rem; }
  .contact-form button[type="submit"] { width: auto; padding: 12px 30px; }
}

/* ========================================================================== */
/* Footer */
/* ========================================================================== */
footer.bg-dark { padding: 30px 0; text-align: center; }
footer.bg-dark p { margin: 0; font-size: 0.9rem; color: rgba(255,255,255,0.7); }

/* ========================================================================== */
/* Utility and Responsive Fixes */
/* ========================================================================== */
.bg-light { background-color: var(--light-bg) !important; } /* ok with navbar-light */

.shadow-sm { box-shadow: var(--shadow-sm) !important; }
.shadow-md { box-shadow: var(--shadow-md) !important; }
.shadow-lg { box-shadow: var(--shadow-lg) !important; }

@media (max-width: 767px) {
  .row { margin-left: -10px; margin-right: -10px; }
  [class*="col-"] { padding-left: 10px; padding-right: 10px; }
  .post-card { margin-bottom: 15px; }
}
@media (min-width: 768px) and (max-width: 991px) {
  .col-md-4 { flex: 0 0 50%; max-width: 50%; }
}

#postModalContent img,
.wp-post-image {
  max-width: 100%; height: auto; display: block; margin: 15px auto;
}

/* === Countdown Timer: hide on tablet and mobile === */
/* ⛔ Commented to ensure countdown shows on mobile (you wanted it visible)
@media (max-width: 991px) {
  #countdown { display: none !important; }
}
*/

/* === Form Input UX Fix === */
input, textarea, select { font-size: 16px; touch-action: manipulation; }

/* Dropdown — this forced super narrow width and made items look "missing". */
/* ⛔ Commented to restore Bootstrap default dropdown sizing
.dropdown-menu {
  width: 50px !important;
  min-width: unset !important;
  text-align: right;
  overflow: hidden;
  white-space: nowrap;
  text-overflow: ellipsis;
}
*/

/* Mobile navbar visibility fixes */
@media (max-width: 991.98px) {
  .navbar-collapse {
    background-color: #212529; /* dark panel */
    padding: .75rem 1rem;
    box-shadow: 0 .5rem 1rem rgba(0,0,0,.15);
  }
  .navbar-collapse .nav-link {
    color: #fff !important;
    padding: .5rem .75rem;
  }
  .navbar-collapse .nav-link:hover,
  .navbar-collapse .nav-link:focus,
  .navbar-collapse .nav-link.active {
    color: #ffd166 !important; /* accent */
  }
  .navbar-toggler { border-color: rgba(255,255,255,.35); }
}

/* Ensure modal overlays the sticky header properly */
.modal { z-index: 1080; }
.navbar.sticky-top { z-index: 1030; }

/* Ensure countdown always visible on mobile */
#countdown { display: flex !important; visibility: visible !important; }

/* Improve contrast on bright hero images */
.countdown-number { text-shadow: 0 1px 2px rgba(0,0,0,.4); }
.countdown-label  { text-shadow: 0 1px 2px rgba(0,0,0,.3); }

/* Services modal -> embedded Website Generator iframe */
.rtf-service-frame-wrap {
  margin-top: 0.5rem;
}

.rtf-service-frame-shell {
  position: relative;
  width: 100%;
  /* Big viewport inside modal (tweak as you like) */
  height: calc(100vh - 220px);
  border: 1px solid #ddd;
  border-radius: 8px;
  overflow: hidden;
}

.rtf-service-frame-shell iframe {
  width: 100%;
  height: 100%;
  border: 0;
}

/* ===== Template Forge front-end cards in Services modal ===== */
#servicesModal .rtf-template-card {
  border: none;
  border-radius: 10px;
  overflow: hidden;
  background: transparent;
  cursor: pointer;
  position: relative;
  transition: transform 0.15s ease, box-shadow 0.15s ease;
}

#servicesModal .rtf-template-card img.card-img-top {
  width: 100%;
  height: 200px;
  object-fit: cover;
  display: block;
}

/* Subtle dark gradient + title overlay at bottom */
#servicesModal .rtf-template-card .card-body {
  position: absolute;
  inset: auto 0 0 0;
  padding: 0.5rem 0.75rem;
  background: linear-gradient(to top, rgba(0,0,0,0.75), rgba(0,0,0,0));
  color: #fff;
}

#servicesModal .rtf-template-card .card-title {
  font-size: 0.9rem;
  margin: 0;
  text-align: left;
}

/* Hover effect */
#servicesModal .rtf-template-card:hover {
  transform: translateY(-2px);
  box-shadow: 0 10px 20px rgba(0,0,0,0.18);
}

/* Selected card (the one you clicked / previewing) */
#servicesModal .rtf-template-card.border-primary,
#servicesModal .rtf-template-card.border.border-2.border-primary {
  box-shadow: 0 0 0 3px #0d6efd;
  transform: translateY(-2px);
}


#sociablendUpdates h2 {
  font-size: 2.2rem;
  font-weight: 700;
  margin-bottom: 40px;
  letter-spacing: 1px;
}

/* Cards */
#sociablendUpdates .card {
  border: none;
  border-radius: 12px;
  overflow: hidden;
  box-shadow: 0 4px 12px rgba(0,0,0,.35);
  transition: transform .2s ease, box-shadow .2s ease;
}

#sociablendUpdates .card:hover {
  transform: translateY(-5px);
  box-shadow: 0 8px 18px rgba(0,0,0,.45);
}

/* Thumbnail images */
.sociablend-thumb {
  height: 180px;
  width: 100%;
  object-fit: cover;
  border-bottom: 2px solid #007bff;
}

/* Card Body */
#sociablendUpdates .card-body {
  display: flex;
  flex-direction: column;
}

#sociablendUpdates .card-title {
  font-size: 1.25rem;
  font-weight: 600;
  color: #000;
}

#sociablendUpdates .card-text {
  color: #333;
}

/* Buttons */
#sociablendUpdates .btn-primary {
  border-radius: 8px;
  background-color: #007bff;
  border: none;
  font-weight: 600;
}

#sociablendUpdates .btn-primary:hover {
  background-color: #0056d6;
}

.sociablend-thumb {
  height: 160px;
  object-fit: cover;
  width: 100%;
}

/* Outer wrapper remains glass */
.sociablend-glass-wrapper {
  background: radial-gradient(circle at top left, rgba(0, 123, 255, 0.25), rgba(0, 0, 0, 0.85));
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border-radius: 1.5rem;
  box-shadow: 0 18px 40px rgba(0, 0, 0, 0.45);
  border: 1px solid rgba(255, 255, 255, 0.08);
}

/* Card uses glass appearance */
.sociablend-card.glass-card {
  background: rgba(255, 255, 255, 0.9);  /* ← back to clean light mode inside */
  border-radius: 1.25rem;
  overflow: hidden;
  box-shadow: 0 10px 24px rgba(0, 0, 0, 0.5);
  transition: transform 0.18s ease, box-shadow 0.18s ease, border-color 0.18s ease;
  border: 1px solid rgba(255, 255, 255, 0.18);
}

/* Hover — keep nice pop effect */
.sociablend-card.glass-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 18px 40px rgba(0, 0, 0, 0.7);
  border-color: rgba(0, 123, 255, 0.4);
}

/* Restore default readable text styling */
.sociablend-card .card-title {
  color: #212529;   /* dark bootstrap text */
  font-weight: 600;
}

.sociablend-card .card-text {
  color: #495057;   /* bootstrap muted gray */
}

/* Thumbnail frame */
.sociablend-thumb {
  width: 100%;
  height: 180px;
  object-fit: cover;
}

/* Button — keep rounded but nicer contrast */
.sociablend-card .btn-primary {
  border-radius: 50px;
  font-weight: 600;
}
