/* ==========================================================
   THEME
   ========================================================== */
:root {
  --bg: #0b1220;
  --bg-secondary: #111a2e;
  --blue: #60a5fa;
  --cyan: #22d3ee;

  --white: #f8fbff;
  --text: #e7eef9;
  --muted: #a9b7cc;
  --muted-2: #8292aa;

  --border: rgba(96, 165, 250, 0.25);
  --border-hover: rgba(34, 211, 238, 0.68);

  --card: rgba(11, 18, 32, 0.78);
  --link-bg: rgba(17, 26, 46, 0.82);
}

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

html {
  min-height: 100%;
  background: var(--bg);
  scroll-behavior: smooth;
}

body {
  min-height: 100vh;
  min-height: 100svh;
  overflow-x: hidden;
  position: relative;
  isolation: isolate;

  color: var(--white);
  background: var(--bg);

  font-family: "Cairo", system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

button,
a {
  font: inherit;
}

a {
  color: inherit;
}

/* ==========================================================
   BACKGROUND IMAGE
   ========================================================== */
body::before {
  content: "";
  position: fixed;
  inset: 0;
  z-index: -3;
  pointer-events: none;

  background-image: url("images/background.jpg");
  background-repeat: no-repeat;
  background-size: cover;
  background-position: 72% center;

  transform: scale(1.03);
}

/* ==========================================================
   BACKGROUND OVERLAY
   ========================================================== */
body::after {
  content: "";
  position: fixed;
  inset: 0;
  z-index: -2;
  pointer-events: none;

  background:
    linear-gradient(
      180deg,
      rgba(11, 18, 32, 0.20) 0%,
      rgba(11, 18, 32, 0.40) 55%,
      rgba(11, 18, 32, 0.5) 100%
    );
}

.background-glow {
  position: fixed;
  inset: 0;
  z-index: -1;
  pointer-events: none;

  background:
    radial-gradient(circle at 78% 24%, rgba(34, 211, 238, 0.11), transparent 24%),
    radial-gradient(circle at 22% 76%, rgba(96, 165, 250, 0.10), transparent 30%);
}

/* ==========================================================
   PAGE
   ========================================================== */
.page {
  width: 100%;
  min-height: 100vh;
  min-height: 100svh;

  display: flex;
  justify-content: center;
  align-items: center;

  padding: clamp(24px, 5vw, 60px) 16px;
}

/* ==========================================================
   MAIN CARD
   ========================================================== */
.links-card {
  width: min(100%, 520px);
  padding: clamp(24px, 5vw, 38px);

  border: 1px solid var(--border);
  border-radius: 28px;

  background:
    linear-gradient(
      145deg,
      rgba(17, 26, 46, 0.88),
      rgba(11, 18, 32, 0.78)
    );

  backdrop-filter: blur(18px);
  -webkit-backdrop-filter: blur(18px);

  box-shadow:
    0 25px 80px rgba(0, 0, 0, 0.45),
    inset 0 1px 0 rgba(255, 255, 255, 0.06),
    0 0 45px rgba(34, 211, 238, 0.05);
}

/* ==========================================================
   PROFILE
   ========================================================== */
.profile {
  text-align: center;
  margin-bottom: 26px;
}

.avatar {
  width: 98px;
  height: 98px;
  display: block;
  margin: 0 auto 15px;

  object-fit: cover;
  object-position: center;
  border-radius: 50%;

  border: 4px solid transparent;
  background:
    linear-gradient(var(--bg-secondary), var(--bg-secondary)) padding-box,
    linear-gradient(135deg, var(--blue), var(--cyan)) border-box;

  box-shadow:
    0 0 0 5px rgba(96, 165, 250, 0.07),
    0 0 35px rgba(34, 211, 238, 0.18);
}

.profile h1 {
  margin-bottom: 6px;

  color: var(--white);

  font-family: "Cairo", sans-serif;
  font-size: clamp(25px, 6vw, 32px);
  font-weight: 800;
  line-height: 1.35;
  letter-spacing: -0.4px;
}

.bio {
  color: var(--muted);

  font-family: "Cairo", sans-serif;
  font-size: clamp(12px, 3.5vw, 14px);
  font-weight: 500;
  line-height: 1.85;
}

/* ==========================================================
   SOCIAL ICONS ROW
   ========================================================== */
.social-links {
  margin-top: 15px;

  display: flex;
  justify-content: center;
  align-items: center;
  flex-wrap: wrap;
  gap: 9px;
}

.social-link {
  width: 42px;
  height: 42px;

  display: grid;
  place-items: center;

  border-radius: 13px;
  border: 1px solid rgba(96, 165, 250, 0.18);

  color: var(--text);
  background: rgba(17, 26, 46, 0.68);

  text-decoration: none;
  font-size: 18px;

  transition:
    transform 0.22s ease,
    color 0.22s ease,
    border-color 0.22s ease,
    background 0.22s ease,
    box-shadow 0.22s ease;
}

.social-link:hover {
  color: var(--cyan);
  border-color: rgba(34, 211, 238, 0.58);
  background: rgba(34, 211, 238, 0.10);
  transform: translateY(-3px);
  box-shadow: 0 9px 24px rgba(34, 211, 238, 0.10);
}

.social-link:focus-visible {
  outline: 2px solid var(--cyan);
  outline-offset: 3px;
}

/* ==========================================================
   EMAIL CARD
   ========================================================== */
.email-card {
  width: 100%;
  min-height: 62px;
  margin-top: 16px;

  display: flex;
  align-items: center;
  gap: 12px;

  padding: 10px 13px;

  border-radius: 15px;
  border: 1px solid rgba(96, 165, 250, 0.16);

  background: rgba(17, 26, 46, 0.72);

  color: var(--text);
  text-decoration: none;

  transition:
    transform 0.22s ease,
    border-color 0.22s ease,
    background 0.22s ease,
    box-shadow 0.22s ease;
}

.email-card:hover {
  transform: translateY(-2px);
  border-color: rgba(34, 211, 238, 0.48);
  background: rgba(34, 211, 238, 0.07);
  box-shadow: 0 10px 26px rgba(34, 211, 238, 0.08);
}

.email-card:focus-visible {
  outline: 2px solid var(--cyan);
  outline-offset: 3px;
}

.email-icon {
  width: 39px;
  height: 39px;
  flex: 0 0 39px;

  display: grid;
  place-items: center;

  border-radius: 11px;
  border: 1px solid rgba(34, 211, 238, 0.18);
  background: rgba(34, 211, 238, 0.07);

  color: var(--cyan);
  font-size: 16px;
}

.email-content {
  min-width: 0;
  flex: 1;
  text-align: right;
}

.email-title {
  display: block;
  margin-bottom: 2px;

  font-family: "Cairo", sans-serif;
  font-size: 12px;
  font-weight: 700;
  line-height: 1.5;
}

.email-address {
  display: block;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;

  direction: ltr;
  text-align: right;

  font-family: "Inter", sans-serif;
  font-size: 10.5px;
  font-weight: 500;
  color: #8292aa;
}



/* ==========================================================
   SECTION TITLE
   ========================================================== */
.link-section {
  width: 100%;
}

.section-title {
  margin: 0 4px 11px;

  color: var(--text);

  font-family: "Cairo", sans-serif;
  font-size: 13px;
  font-weight: 700;
  line-height: 1.6;

  text-align: right;
}

/* ==========================================================
   LINKS
   ========================================================== */
.links {
  display: grid;
  gap: 11px;
}

.link {
  min-height: 64px;
  width: 100%;

  display: flex;
  align-items: center;
  gap: 12px;

  padding: 10px 13px;

  border: 1px solid rgba(96, 165, 250, 0.20);
  border-radius: 17px;

  color: var(--white);
  background:
    linear-gradient(
      135deg,
      rgba(17, 26, 46, 0.92),
      rgba(11, 18, 32, 0.84)
    );

  text-decoration: none;

  transition:
    transform 0.22s ease,
    border-color 0.22s ease,
    background 0.22s ease,
    box-shadow 0.22s ease;
}

.link:hover {
  transform: translateY(-2px);
  border-color: var(--border-hover);

  background:
    linear-gradient(
      135deg,
      rgba(96, 165, 250, 0.14),
      rgba(34, 211, 238, 0.09)
    );

  box-shadow: 0 12px 30px rgba(34, 211, 238, 0.09);
}

.link:active {
  transform: translateY(0) scale(0.99);
}

.link:focus-visible {
  outline: 2px solid var(--cyan);
  outline-offset: 3px;
}

/* ==========================================================
   LINK ICON
   ========================================================== */
.icon {
  width: 43px;
  height: 43px;
  flex: 0 0 43px;

  display: grid;
  place-items: center;

  border: 1px solid rgba(34, 211, 238, 0.18);
  border-radius: 13px;

  color: var(--cyan);
  background: rgba(34, 211, 238, 0.07);
  font-size: 19px;

  transition:
    transform 0.22s ease,
    color 0.22s ease,
    background 0.22s ease,
    border-color 0.22s ease;
}

.link:hover .icon {
  color: #ffffff;
  border-color: rgba(34, 211, 238, 0.35);
  background: linear-gradient(
    135deg,
    rgba(96, 165, 250, 0.25),
    rgba(34, 211, 238, 0.17)
  );
  transform: scale(1.04);
}

/* ==========================================================
   LINK TEXT
   ========================================================== */
.link-text {
  min-width: 0;
  flex: 1;
  text-align: right;
}

.link-title {
  display: block;
  margin-bottom: 2px;

  color: var(--white);

  font-family: "Cairo", sans-serif;
  font-size: 14px;
  font-weight: 700;
  line-height: 1.45;
}

.link-subtitle {
  display: block;
  max-width: 100%;

  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;

  color: var(--muted-2);

  font-family: "Inter", "Cairo", sans-serif;
  font-size: 10.5px;
  font-weight: 500;
  line-height: 1.5;

  direction: ltr;
  text-align: right;
}

/* ==========================================================
   ARROW
   ========================================================== */
.arrow {
  width: 24px;
  flex: 0 0 24px;

  color: var(--blue);
  font-size: 16px;
  text-align: center;

  transition:
    transform 0.22s ease,
    color 0.22s ease;
}

.link:hover .arrow {
  color: var(--cyan);
  transform: translateX(-3px);
}

/* ==========================================================
   FOOTER
   ========================================================== */
.footer {
  margin-top: 20px;

  color: #71819a;

  font-family: "Inter", "Cairo", sans-serif;
  font-size: 9.5px;
  font-weight: 500;
  line-height: 1.7;
  text-align: center;
}

/* ==========================================================
   TABLET
   ========================================================== */
@media (min-width: 701px) and (max-width: 1100px) {
  body::before {
    background-size: cover;
    background-position: 68% center;
  }
}

/* ==========================================================
   MOBILE
   ========================================================== */
@media (max-width: 700px) {
  body::before {
    background-size: auto 100svh;
    background-position: 76% center;
    transform: scale(1.02);
  }



  .page {
    min-height: 100svh;
    align-items: flex-start;
    padding: 26px 11px;
  }

  .links-card {
    width: 100%;
    max-width: 520px;
    padding: 23px 14px 20px;
    border-radius: 24px;
  }

  .profile {
    margin-bottom: 23px;
  }

  .avatar {
    width: 88px;
    height: 88px;
    margin-bottom: 13px;
  }

  .profile h1 {
    font-size: 27px;
  }

  .bio {
    font-size: 13px;
  }

  .social-links {
    margin-top: 13px;
    gap: 8px;
  }

  .social-link {
    width: 40px;
    height: 40px;
    border-radius: 12px;
    font-size: 17px;
  }

  .email-card {
    min-height: 58px;
    margin-top: 13px;
    padding: 9px 11px;
    border-radius: 14px;
    gap: 10px;
  }

  .email-icon {
    width: 37px;
    height: 37px;
    flex-basis: 37px;
    border-radius: 10px;
    font-size: 15px;
  }

  .email-title {
    font-size: 11.5px;
  }

  .email-address {
    font-size: 10px;
  }

  .section-title {
    margin-bottom: 10px;
    font-size: 12.5px;
  }

  .links {
    gap: 10px;
  }

  .link {
    min-height: 60px;
    padding: 9px 11px;
    border-radius: 15px;
    gap: 10px;
  }

  .icon {
    width: 40px;
    height: 40px;
    flex-basis: 40px;
    border-radius: 12px;
    font-size: 18px;
  }

  .link-title {
    font-size: 13.5px;
  }

  .link-subtitle {
    font-size: 10px;
  }

  .arrow {
    width: 21px;
    flex-basis: 21px;
    font-size: 15px;
  }
}

/* ==========================================================
   SMALL MOBILE
   ========================================================== */
@media (max-width: 480px) {
  body::before {
    background-size: auto 100svh;
    background-position: 78% center;
  }

  .page {
    padding: 18px 8px;
  }

  .links-card {
    padding: 20px 11px 18px;
    border-radius: 21px;
  }

  .avatar {
    width: 82px;
    height: 82px;
  }

  .profile h1 {
    font-size: 24px;
  }

  .bio {
    font-size: 12.5px;
  }

  .social-links {
    margin-top: 12px;
  }

  .social-link {
    width: 38px;
    height: 38px;
    border-radius: 11px;
    font-size: 16px;
  }

  .link {
    min-height: 57px;
    padding: 8px 9px;
    border-radius: 14px;
  }

  .icon {
    width: 37px;
    height: 37px;
    flex-basis: 37px;
    border-radius: 10px;
    font-size: 17px;
  }

  .link-title {
    font-size: 13px;
  }

  .link-subtitle {
    font-size: 9.5px;
  }

  .arrow {
    font-size: 14px;
  }
}

/* ==========================================================
   VERY SMALL PHONES
   ========================================================== */
@media (max-width: 360px) {
  body::before {
    background-position: 80% center;
  }

  .page {
    padding: 13px 6px;
  }

  .links-card {
    padding: 17px 9px 16px;
    border-radius: 19px;
  }

  .avatar {
    width: 74px;
    height: 74px;
    border-width: 3px;
  }

  .profile {
    margin-bottom: 19px;
  }

  .profile h1 {
    font-size: 22px;
  }

  .bio {
    font-size: 11.5px;
  }

  .social-link {
    width: 35px;
    height: 35px;
    font-size: 15px;
  }

  .links {
    gap: 8px;
  }

  .link {
    min-height: 53px;
    padding: 7px;
  }

  .icon {
    width: 34px;
    height: 34px;
    flex-basis: 34px;
    border-radius: 9px;
    font-size: 15px;
  }

  .link-title {
    font-size: 12px;
  }

  .link-subtitle {
    font-size: 8.7px;
  }

  .arrow {
    width: 19px;
    flex-basis: 19px;
    font-size: 13px;
  }

  .footer {
    font-size: 8.5px;
  }
}

/* ==========================================================
   REDUCED MOTION
   ========================================================== */
@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    animation: none !important;
    transition: none !important;
    scroll-behavior: auto !important;
  }
}
