/*
Theme Name: Masaf Link Hub
Author: Masaf
Description: A compact Linkfree-style WordPress theme for creator links.
Version: 1.1.0
Requires at least: 6.0
Tested up to: 6.8
Requires PHP: 7.4
License: GPL-2.0-or-later
Text Domain: masaf-linkhub
*/

:root {
  --page: #9c9d9d;
  --surface: #e9eaec;
  --card: #ffffff;
  --ink: #030303;
  --muted: #33373d;
  --soft: #6a6d72;
  --line: rgba(0, 0, 0, 0.05);
  --shadow: 0 14px 36px rgba(0, 0, 0, 0.06);
  font-family: Inter, "Noto Sans JP", "Hiragino Kaku Gothic ProN", Meiryo, sans-serif;
}

* {
  box-sizing: border-box;
}

html {
  min-height: 100%;
  background: var(--page);
}

body {
  min-height: 100vh;
  margin: 0;
  color: var(--ink);
  background: var(--page);
}

a {
  color: inherit;
}

.linkhub-shell {
  position: relative;
  width: 100%;
  max-width: 696px;
  min-height: 100vh;
  margin: 0 auto;
  padding: 30px 32px 36px;
  background: var(--surface);
  overflow-x: hidden;
}

.linkhub-topbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 2px;
}

.icon-button {
  display: inline-grid;
  place-items: center;
  width: 50px;
  height: 50px;
  border: 0;
  border-radius: 18px;
  background: var(--card);
  color: var(--ink);
  box-shadow: 0 1px 0 rgba(255, 255, 255, 0.6);
}

.icon-button svg {
  width: 25px;
  height: 25px;
  stroke-width: 2;
}

.linkhub-profile {
  display: grid;
  justify-items: center;
  margin-top: -28px;
  text-align: center;
}

.profile-avatar {
  position: relative;
  width: 104px;
  height: 104px;
  overflow: hidden;
  border-radius: 50%;
  background: #15171a;
  box-shadow: 0 1px 0 rgba(255, 255, 255, 0.7);
}

.profile-avatar img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.profile-avatar::after {
  position: absolute;
  right: 13px;
  bottom: 14px;
  left: 13px;
  height: 18px;
  border-radius: 999px;
  background: rgba(0, 0, 0, 0.3);
  content: "";
}

.avatar-label {
  position: absolute;
  right: 12px;
  bottom: 16px;
  left: 12px;
  z-index: 1;
  color: #fff;
  font-size: 0.62rem;
  font-weight: 800;
  line-height: 1;
  text-shadow: 0 1px 6px rgba(0, 0, 0, 0.45);
}

.site-title {
  max-width: 36rem;
  margin: 19px 0 5px;
  font-size: clamp(1.65rem, 4.2vw, 1.95rem);
  line-height: 1.32;
  letter-spacing: 0;
  font-weight: 900;
  overflow-wrap: anywhere;
}

.site-lead {
  max-width: 31rem;
  margin: 0;
  color: var(--ink);
  font-size: clamp(1rem, 3vw, 1.15rem);
  font-weight: 700;
  line-height: 1.62;
}

.links-panel {
  margin-top: 39px;
}

.links-list {
  display: grid;
  gap: 16px;
}

.link-tile {
  position: relative;
  display: grid;
  grid-template-columns: 58px minmax(0, 1fr) 28px;
  gap: 18px;
  align-items: center;
  min-height: 78px;
  padding: 10px 17px 10px 10px;
  border: 1px solid var(--line);
  border-radius: 10px;
  background: var(--card);
  box-shadow: var(--shadow);
  text-decoration: none;
  transition: transform 160ms ease, box-shadow 160ms ease;
}

.link-tile:hover,
.link-tile:focus-visible {
  outline: none;
  box-shadow: 0 18px 42px rgba(0, 0, 0, 0.1);
  transform: translateY(-2px);
}

.link-thumb {
  position: relative;
  width: 58px;
  height: 58px;
  overflow: hidden;
  border-radius: 7px;
  background: linear-gradient(135deg, var(--accent), #111);
}

.link-thumb img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.link-thumb::after {
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, transparent 48%, rgba(0, 0, 0, 0.36));
  content: "";
}

.thumb-mark {
  position: absolute;
  right: 5px;
  bottom: 5px;
  z-index: 1;
  color: #fff;
  font-size: 0.64rem;
  font-weight: 900;
  line-height: 1;
  text-shadow: 0 1px 5px rgba(0, 0, 0, 0.45);
}

.link-body {
  min-width: 0;
  text-align: center;
}

.link-name {
  display: block;
  overflow-wrap: anywhere;
  font-size: clamp(1rem, 3.1vw, 1.18rem);
  font-weight: 900;
  line-height: 1.35;
}

.link-desc {
  display: block;
  margin-top: 3px;
  color: var(--soft);
  font-size: 0.78rem;
  font-weight: 700;
  line-height: 1.3;
}

.link-action {
  display: inline-grid;
  place-items: center;
  justify-self: end;
  width: 24px;
  height: 34px;
  color: #161616;
}

.link-action svg {
  width: 22px;
  height: 22px;
  stroke-width: 1.8;
}

.adult-badge {
  position: absolute;
  top: 7px;
  right: 45px;
  min-width: 29px;
  padding: 3px 6px;
  border-radius: 999px;
  background: #0d0d0d;
  color: #fff;
  font-size: 0.68rem;
  font-weight: 900;
  text-align: center;
}

.linkhub-footer {
  display: flex;
  justify-content: center;
  margin-top: 26px;
  color: var(--soft);
  font-size: 0.78rem;
  font-weight: 700;
}

@media (max-width: 520px) {
  .linkhub-shell {
    padding: 28px 13px 32px;
  }

  .icon-button {
    width: 50px;
    height: 50px;
    border-radius: 18px;
  }

  .linkhub-profile {
    margin-top: -22px;
  }

  .profile-avatar {
    width: 94px;
    height: 94px;
  }

  .site-title {
    margin-top: 17px;
    max-width: 100%;
    font-size: 1.45rem;
  }

  .links-panel {
    margin-top: 42px;
  }

  .links-list {
    gap: 14px;
  }

  .link-tile {
    grid-template-columns: 48px minmax(0, 1fr) 24px;
    gap: 12px;
    min-height: 74px;
    padding: 9px 14px 9px 9px;
  }

  .link-thumb {
    width: 48px;
    height: 48px;
  }
}
