/* common.css */
/* =========================================================
  Base / Reset
========================================================= */
@font-face {
  font-family: "Inter";
  font-style: normal;
  font-weight: 400;
  font-display: swap;
  src: url("../fonts/inter-400.woff2") format("woff2");
}

@font-face {
  font-family: "Inter";
  font-style: normal;
  font-weight: 500;
  font-display: swap;
  src: url("../fonts/inter-500.woff2") format("woff2");
}

@font-face {
  font-family: "Inter";
  font-style: normal;
  font-weight: 700;
  font-display: swap;
  src: url("../fonts/inter-700.woff2") format("woff2");
}

@font-face {
  font-family: "Inter";
  font-style: normal;
  font-weight: 800;
  font-display: swap;
  src: url("../fonts/inter-800.woff2") format("woff2");
}

@font-face {
  font-family: "Material Symbols Outlined";
  font-style: normal;
  font-weight: 100 700;
  font-display: block;
  src: url("../fonts/material-symbols-outlined.woff2") format("woff2");
}

.material-symbols-outlined {
  font-family: "Material Symbols Outlined";
  font-weight: normal;
  font-style: normal;
  font-size: 24px;
  line-height: 1;
  letter-spacing: normal;
  text-transform: none;
  display: inline-block;
  white-space: nowrap;
  word-wrap: normal;
  direction: ltr;
  -moz-font-feature-settings: "liga";
  -moz-osx-font-smoothing: grayscale;
  font-variation-settings: "FILL" 0, "wght" 400, "GRAD" 0, "opsz" 24;
}

:root {
  --bg: #f3f4f6;
  --panel: #fff;
  --panel-strong: rgb(240, 248, 250);
  --stroke: rgba(20, 40, 60, 0.10);
  --stroke-strong: rgba(20, 40, 60, 0.16);

  --text: rgba(20, 30, 40, 0.88);
  --muted: rgba(20, 30, 40, 0.55);
  --muted-2: rgba(20, 30, 40, 0.40);

  --primary: #1a6ef2;
  --primary-2: #2b8affe9;
  --primary-rgb: 31, 122, 255;

  --radius-lg: 14px;
  --radius-md: 10px;
  --radius-sm: 6px;

  --shadow: 0 10px 30px rgba(12, 30, 50, 0.08);
  --shadow-soft: 0 6px 18px rgba(12, 30, 50, 0.06);

  --container: 1060px;

  --ring-bg: #dbeafe;
  --ring-fg: #1a6ef2;

  --focus: 0 0 0 4px rgba(var(--primary-rgb), 0.18);
}

body.is-break {
  --primary: #2b7a6e;
  --primary-2: #3a8f83;
  --primary-rgb: 43, 122, 110;
  --ring-bg: #d7ede8;
  --ring-fg: #2b7a6e;
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

*,
*::before,
*::after {
  border-radius: 0 !important;
}

html,
body {
  height: 100%;
}

.visually-hidden {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

body {
  margin: 0;
  font-family: "Inter", system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  color: var(--text);
  background: var(--bg);
  line-height: 1.45;
}

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

a:hover {
  text-decoration: underline;
}

button,
input {
  font: inherit;
}

button {
  cursor: pointer;
}

button:disabled {
  cursor: not-allowed;
}

/* =========================================================
  Header
========================================================= */
.site-header {
  position: sticky;
  top: 0;
  z-index: 10;
  background: transparent;
  backdrop-filter: none;
  border-bottom: none;
}

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

.brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
}

.brand-icon {
  width: 30px;
  height: 30px;
  display: block;
  flex-shrink: 0;
  color: var(--primary);
  background-color: currentColor;
  -webkit-mask-image: url("../icons/logo-sharktimer.svg");
  -webkit-mask-repeat: no-repeat;
  -webkit-mask-position: center;
  -webkit-mask-size: contain;
  mask-image: url("../icons/logo-sharktimer.svg");
  mask-repeat: no-repeat;
  mask-position: center;
  mask-size: contain;
  transition: background-color 300ms ease, color 300ms ease;
}

.brand-name {
  font-size: 18px;
  font-weight: 700;
  letter-spacing: 0.2px;
}

.header-actions {
  display: inline-flex;
  align-items: center;
  gap: 10px;
}

.icon-btn {
  width: 40px;
  height: 40px;
  border-radius: 999px;
  border: 1px solid transparent;
  background: transparent;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  box-shadow: none;
  transition: transform 120ms ease, background 300ms ease, border-color 300ms ease;
}

.icon-btn .material-symbols-outlined {
  font-size: 22px;
  color: rgba(20, 30, 40, 0.70);
  transition: color 300ms ease;
}

.icon-btn:hover:not(:disabled) {
  background: rgba(255, 255, 255, 0.45);
  border-color: var(--stroke);
}

.icon-btn:active:not(:disabled) {
  transform: translateY(1px);
}

.icon-btn:focus-visible {
  outline: none;
  background: rgba(255, 255, 255, 0.45);
  border-color: var(--stroke);
}

.icon-btn.is-primary {
  border-color: rgba(var(--primary-rgb), 0.35);
  background: rgba(var(--primary-rgb), 0.10);
}

.icon-btn.is-primary .material-symbols-outlined {
  color: var(--primary);
}

/* =========================================================
  Header: tools menu
========================================================= */
.tools-menu {
  position: relative;
}

.tools-menu > summary {
  list-style: none;
  cursor: pointer;
}

.tools-menu > summary::-webkit-details-marker {
  display: none;
}

.tools-dropdown {
  position: absolute;
  right: 0;
  top: calc(100% + 8px);
  min-width: 220px;
  padding: 8px;
  background: var(--panel);
  border: 1px solid var(--stroke);
  border-radius: 14px;
  box-shadow: var(--shadow);
}

.tools-item {
  display: block;
  padding: 10px 12px;
  border-radius: 12px;
  color: var(--text);
  text-decoration: none;
  transition: background 200ms ease, transform 120ms ease;
}

.tools-item:hover,
.tools-item:focus-visible {
  background: rgba(var(--primary-rgb), 0.10);
  outline: none;
}

.tools-item:active {
  transform: translateY(1px);
}

/* =========================================================
  Footer
========================================================= */
.site-footer {
  margin-top: 12px;
  border-top: 1px solid var(--stroke);
  background: #fff;
}

.footer-inner {
  max-width: var(--container);
  margin: 0 auto;
  padding: 18px 20px;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 10px;
  color: rgba(20, 30, 40, 0.52);
  text-align: center;
}

.copyright {
  color: #595959;
}

.footer-legal {
  display: inline-flex;
  flex-wrap: wrap;
  justify-content: center;
  row-gap: 6px;
  column-gap: 0;
  color: #595959;
  font-size: 14px;
}

.footer-legal a {
  color: inherit;
}

.footer-legal a + a::before {
  content: "|";
  color: rgba(20, 30, 40, 0.35);
  margin: 0 8px;
}

/* =========================================================
  Footer: tools links (compact)
========================================================= */
.footer-tools {
  width: 100%;
  margin-top: 10px;
  padding-top: 12px;
  border-top: 1px solid var(--stroke);
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 8px 14px;
}

.footer-tools a {
  color: var(--muted);
  text-decoration: none;
  font-size: 14px;
}

.footer-tools a:hover,
.footer-tools a:focus-visible {
  color: var(--text);
  text-decoration: underline;
}

body.page-home .footer-tools-links {
  display: none;
}

/* =========================================================
  Dark Theme (shared)
========================================================= */
body.theme-dark {
  color-scheme: dark;
  --bg: #0f172a;
  --panel: #000;
  --panel-strong: #000;
  --stroke: rgba(148, 163, 184, 0.18);
  --stroke-strong: rgba(148, 163, 184, 0.28);
  --text: #e9e9e9;
  --muted: #e9e9e9;
  --muted-2: #e9e9e9;
  --primary: #60a5fa;
  --primary-2: #3b82f6;
  --primary-rgb: 96, 165, 250;
  --ring-bg: rgba(96, 165, 250, 0.32);
  --ring-fg: #60a5fa;
}

body.theme-dark.is-break {
  --primary: #339183;
  --primary-2: #45a697;
  --primary-rgb: 51, 145, 131;
  --ring-bg: #d3ebe8;
  --ring-fg: #339183;
}

body.theme-dark .site-header {
  background: transparent;
  border-bottom: none;
}

body.theme-dark .icon-btn {
  background: transparent;
  border-color: transparent;
}

body.theme-dark .icon-btn:hover:not(:disabled) {
  background: rgba(15, 23, 42, 0.6);
  border-color: var(--stroke);
}

body.theme-dark .icon-btn:focus-visible {
  background: rgba(15, 23, 42, 0.6);
  border-color: var(--stroke);
}

body.theme-dark .icon-btn .material-symbols-outlined {
  color: var(--muted);
}

body.theme-dark .footer-inner,
body.theme-dark .footer-legal a {
  color: var(--muted);
}

body.theme-dark .copyright {
  color: #e9e9e9;
}

body.theme-dark .site-footer {
  background: rgba(15, 23, 42, 0.6);
}
