/* Reset */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

body {
  font-family: "Inter", Arial, sans-serif;
  overflow-x: hidden;
  transition: background 0.3s, color 0.3s;
}

/* Dark mode (default) */
body.dark {
  background: #0b0b0b;
  color: white;
}

/* Light mode */
body.light {
  background: #f5f5f5;
  color: #111;
}

/* Hemlig knapp */
.secret-dot {
  position: fixed;
  bottom: 22px;
  right: 22px;
  font-size: 26px;
  opacity: 0.35;
  cursor: pointer;
  user-select: none;
  transition: 0.2s;
  z-index: 999;
}
.secret-dot:hover {
  opacity: 0.65;
}

/* Navbar */
.navbar {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 18px 24px;
  background: var(--nav-bg);
  border-bottom: 1px solid var(--nav-border);
  position: sticky;
  top: 0;
  z-index: 10;
}

body.dark {
  --nav-bg: #111;
  --nav-border: #222;
}
body.light {
  --nav-bg: #ffffff;
  --nav-border: #ddd;
}

.logo {
  font-size: 22px;
  font-weight: 600;
  text-decoration: none;
}

.theme-btn {
  background: var(--btn-bg);
  border: none;
  padding: 10px 14px;
  border-radius: 10px;
  font-size: 18px;
  cursor: pointer;
  transition: 0.2s;
}

body.dark {
  --btn-bg: #222;
}
body.light {
  --btn-bg: #e6e6e6;
}

.theme-btn:hover {
  opacity: 0.8;
}

/* Hero */
.hero {
  text-align: center;
  padding: 30px 20px;
}
.hero h1 {
  font-size: 42px;
  margin-bottom: 10px;
  color: var(--accent);
}
.hero p {
  font-size: 18px;
  opacity: 0.8;
}

body.dark {
  --accent: #ffcc00;
}
body.light {
  --accent: #cc9900;
}

/* Tiles */
.tiles {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 22px;
  padding: 30px;
}

.tile {
  background: var(--tile-bg);
  padding: 28px;
  border-radius: 18px;
  text-decoration: none;
  color: inherit;
  box-shadow: var(--tile-shadow);
  transition: 0.25s;
  display: flex;
  flex-direction: column;
  gap: 10px;
}

body.dark {
  --tile-bg: #141414;
  --tile-shadow: 0 0 25px rgba(255,255,255,0.05);
}
body.light {
  --tile-bg: #ffffff;
  --tile-shadow: 0 0 20px rgba(0,0,0,0.08);
}

.tile:hover {
  transform: translateY(-4px);
}

.icon {
  font-size: 40px;
}

.tile h2 {
  font-size: 22px;
  font-weight: 600;
}

.tile p {
  opacity: 0.75;
  font-size: 15px;
}

/* Mobile adjustments */
@media (max-width: 500px) {
  .hero h1 {
    font-size: 32px;
  }
  .tile {
    padding: 24px;
  }
  .tile h2 {
    font-size: 20px;
  }
  .icon {
    font-size: 36px;
  }
}

/* Global footer */
footer {
  text-align: center;
  padding: 20px;
  opacity: 0.5;
  font-size: 14px;
  margin-top: 40px;
}

footer {
  text-align: center;
  padding: 25px;
  opacity: 0.6;
  font-size: 15px;
  margin-top: 40px;
}

footer a {
  color: var(--accent);
  text-decoration: none;
  font-weight: 600;
}

footer a:hover {
  opacity: 0.8;
}

input, textarea {
  padding: 10px;
  border-radius: 10px;
  border: 1px solid var(--nav-border);
  background: var(--tile-bg);
  color: inherit;
  font-size: 15px;
}

input:focus, textarea:focus {
  outline: 2px solid var(--accent);
}

/* NY! - flagga */

.new-badge {
    position: absolute;
    top: -6px;
    right: -6px;
    background: #ff3b3b;
    color: #fff;
    font-size: 0.65rem;
    font-weight: 700;
    padding: 3px 6px;
    border-radius: 6px;
    box-shadow: 0 2px 6px rgba(0,0,0,0.25);
    pointer-events: none;
    z-index: 5;
}

.tile {
    position: relative; /* viktigt! */
}
