:root {
  --bg-light: #f5f5f5;
  --text-light: #333;
  --bg-dark: #121212;
  --text-dark: #f5f5f5;
  --accent: #4f46e5;
}

[data-theme="light"] {
  background-color: var(--bg-light);
  color: var(--text-light);
}

[data-theme="dark"] {
  background-color: var(--bg-dark);
  color: var(--text-dark);
}

body {
  margin: 0;
  font-family: 'Segoe UI', Arial, sans-serif;
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: 2em;
  text-align: center;
  min-height: 100vh;
  transition: background-color 0.3s, color 0.3s;
}

h1 {
  font-size: 2rem;
}

.ip-label {
  font-weight: bold;
  margin-top: 1em;
}

.ip-value {
  font-size: 1.3rem;
  color: var(--accent);
}

#flag {
  margin-top: 0.8em;
  font-size: 2.6rem;
  line-height: 1;
}

iframe {
  margin-top: 1em;
  width: 100%;
  max-width: 400px;
  height: 300px;
  border: none;
  border-radius: 8px;
}

.theme-button {
  margin-top: 2em;
  padding: 0.5em 1em;
  background-color: var(--accent);
  color: white;
  border: none;
  border-radius: 6px;
  cursor: pointer;
}

.privacy-status {
  margin-top: 1em;
  max-width: 700px;
  padding: 10px 12px;
  border-radius: 8px;
  border: 1px solid #bdbdbd;
  font-size: 0.95rem;
  line-height: 1.4;
}

.privacy-status.exposed {
  border-color: #d97706;
  background: #fff7ed;
  color: #9a3412;
}

.privacy-status.protected {
  border-color: #15803d;
  background: #f0fdf4;
  color: #166534;
}

.privacy-status.unknown {
  border-color: #475569;
  background: #f8fafc;
  color: #334155;
}

@keyframes pulse {
  0%, 100% { opacity: 1; }
  50% { opacity: 0.4; }
}

.loading {
  animation: pulse 1.5s ease-in-out infinite;
}

/* Content sections */
section {
  max-width: 700px;
  text-align: left;
  line-height: 1.7;
  margin-top: 2em;
}

[dir="rtl"] section {
  text-align: right;
}

section h2 {
  font-size: 1.3rem;
  margin-top: 1.5em;
  margin-bottom: 0.5em;
}

section ul {
  padding-left: 1.5em;
  margin-top: 0.5em;
}

[dir="rtl"] section ul {
  padding-left: 0;
  padding-right: 1.5em;
}

section p {
  margin-top: 0.4em;
}

/* FAQ accordions */
details {
  margin-top: 0.6em;
  border: 1px solid #ddd;
  border-radius: 8px;
  padding: 0;
  overflow: hidden;
}

details summary {
  cursor: pointer;
  padding: 0.7em 1em;
  background: #fafafa;
  list-style: none;
}

details summary::-webkit-details-marker {
  display: none;
}

details summary::before {
  content: "▸ ";
  font-weight: bold;
  color: var(--accent);
}

details[open] summary::before {
  content: "▾ ";
}

details[open] summary {
  border-bottom: 1px solid #ddd;
}

details p {
  padding: 0.7em 1em;
  margin: 0;
}

[data-theme="dark"] details {
  border-color: #444;
}

[data-theme="dark"] details summary {
  background: #1e1e1e;
}

[data-theme="dark"] details[open] summary {
  border-bottom-color: #444;
}
