/* Revision: 2026-03-22 – Initial stylesheet for qbotoolbox.com */
/* Revision: 2026-03-22 – Refactored: global only — variables, reset, container, nav, footer */

/* ===== CSS VARIABLES ===== */
:root {
  --color-bg:          #000000;
  --color-bg-section:  #161616;
  --color-text:        #ffffff;
  --color-text-muted:  #969696;
  --color-text-dim:    #ababab;
  --color-text-light:  #e2e2e2;
  --color-border:      rgba(255, 255, 255, 0.6);
  --color-border-dim:  rgba(119, 119, 119, 0.5);
  --color-btn-bg:      #ffffff;
  --color-btn-text:    #000000;
  --color-btn-hover:   #d4d4d4;
  --color-hr:          #1b1b1b;

  --font-display:      'Playfair Display', Georgia, serif;
  --font-logo:         'Montserrat', sans-serif;
  --font-body:         'Source Sans 3', Arial, sans-serif;

  --container-sm:      984px;
  --container-md:      1160px;
  --container-lg:      1280px;

  --section-pad-y:     56px;
  --section-pad-x:     24px;
}

/* ===== RESET ===== */
*, *::before, *::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
  -webkit-text-size-adjust: 100%;
  -webkit-font-smoothing: antialiased;
}

body {
  background-color: var(--color-bg);
  color: var(--color-text);
  font-family: var(--font-body);
  font-size: 16px;
  line-height: 1.5;
  min-height: 100vh;
}

a {
  color: inherit;
  text-decoration: none;
}

a:hover { color: var(--color-text-dim); }

img {
  max-width: 100%;
  vertical-align: middle;
  border: 0;
}

hr { border: 0; }

/* ===== CONTAINER ===== */
.container {
  width: 100%;
  margin-left: auto;
  margin-right: auto;
  padding-left: var(--section-pad-x);
  padding-right: var(--section-pad-x);
}

@media (min-width: 1024px) { .container { max-width: var(--container-sm); } }
@media (min-width: 1280px) { .container { max-width: var(--container-md); } }
@media (min-width: 1536px) { .container { max-width: var(--container-lg); } }

/* ===== NAV ===== */
.site-nav {
  position: relative;
  z-index: 100;
  width: 100%;
  padding: 0 24px;
}

.nav-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 64px;
  max-width: var(--container-lg);
  margin: 0 auto;
}

.site-logo {
  font-family: var(--font-logo);
  font-size: 18px;
  font-weight: 700;
  color: #ffffff !important;
  text-transform: uppercase;
  letter-spacing: 3px;
  line-height: 1.2;
  text-decoration: none;
  flex-shrink: 0;
}

.site-logo:hover { color: #ffffff !important; }

@media (min-width: 768px)  { .site-logo { font-size: 20px; } }
@media (min-width: 1280px) { .site-logo { font-size: 22px; } }

.nav-links {
  display: none;
  list-style: none;
  align-items: center;
  gap: 8px;
  margin: 0;
  padding: 0;
}

@media (min-width: 768px) { .nav-links { display: flex; } }

.nav-links li { position: relative; }

.nav-links a,
.nav-links button {
  font-family: var(--font-logo);
  font-size: 11px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 2px;
  color: rgba(255,255,255,0.7);
  text-decoration: none;
  padding: 8px 14px;
  border-radius: 4px;
  border: none;
  background: transparent;
  cursor: pointer;
  display: flex;
  align-items: center;
  gap: 4px;
  transition: color 0.2s ease, background-color 0.2s ease;
  white-space: nowrap;
}

.nav-links a:hover,
.nav-links button:hover {
  color: #ffffff;
  background-color: rgba(255,255,255,0.08);
}

.nav-links a.active,
.nav-links button.active { color: #4ade80; }

.nav-dropdown-toggle::after {
  content: '▾';
  font-size: 10px;
  opacity: 0.6;
}

.nav-dropdown {
  display: none;
  position: absolute;
  top: calc(100% + 4px);
  right: 0;
  background-color: #111111;
  border: 1px solid #1f2937;
  border-radius: 6px;
  min-width: 200px;
  padding: 6px;
  box-shadow: 0 8px 24px rgba(0,0,0,0.4);
  z-index: 200;
}

.nav-dropdown.open { display: block; }

.nav-dropdown a {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 10px 14px;
  border-radius: 4px;
  font-size: 11px;
  color: rgba(255,255,255,0.6);
  letter-spacing: 1.5px;
}

.nav-dropdown a:hover {
  background-color: #1f2937;
  color: #ffffff;
}

.nav-dropdown a .tool-badge {
  font-size: 9px;
  background-color: #166534;
  color: #4ade80;
  padding: 2px 6px;
  border-radius: 3px;
  letter-spacing: 1px;
  margin-left: auto;
}

.nav-hamburger {
  display: flex;
  flex-direction: column;
  gap: 5px;
  background: transparent;
  border: none;
  cursor: pointer;
  padding: 8px;
  border-radius: 4px;
}

@media (min-width: 768px) { .nav-hamburger { display: none; } }

.nav-hamburger span {
  display: block;
  width: 22px;
  height: 2px;
  background-color: rgba(255,255,255,0.8);
  border-radius: 2px;
  transition: all 0.25s ease;
}

.nav-hamburger.open span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
.nav-hamburger.open span:nth-child(2) { opacity: 0; }
.nav-hamburger.open span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }

.nav-mobile {
  display: none;
  position: absolute;
  top: 64px;
  left: 0;
  right: 0;
  background-color: #111111;
  border-bottom: 1px solid #1f2937;
  padding: 12px 24px 20px;
  z-index: 99;
}

.nav-mobile.open { display: block; }

.nav-mobile a {
  display: block;
  font-family: var(--font-logo);
  font-size: 11px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 2px;
  color: rgba(255,255,255,0.7);
  padding: 12px 0;
  border-bottom: 1px solid #1f2937;
  text-decoration: none;
}

.nav-mobile a:last-child { border-bottom: none; }
.nav-mobile a:hover { color: #ffffff; }
.nav-mobile a.active { color: #4ade80; }

.nav-mobile-section {
  font-family: var(--font-logo);
  font-size: 9px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 2px;
  color: #374151;
  padding: 16px 0 6px;
}

.tool-nav-bar {
  background-color: #111111;
  border-bottom: 1px solid #1f2937;
  position: relative;
}

/* ===== FOOTER ===== */
.site-footer {
  background-color: var(--color-bg);
  padding-top: var(--section-pad-y);
  padding-bottom: var(--section-pad-y);
}

@media (max-width: 767px) {
  .site-footer {
    padding-top: 40px;
    padding-bottom: 40px;
  }
}

.footer-inner {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
}

@media (min-width: 1024px) {
  .footer-inner {
    flex-direction: row;
    justify-content: space-between;
    text-align: left;
  }
}

.footer-copy {
  font-family: var(--font-body);
  font-size: 12px;
  font-weight: 400;
  color: var(--color-text-muted);
  line-height: 1.5;
}

@media (min-width: 768px)  { .footer-copy { font-size: 14px; } }
@media (min-width: 1536px) { .footer-copy { font-size: 16px; } }
