﻿@import url('https://fonts.googleapis.com/css2?family=Manrope:wght@400;500;600;700;800&family=Fraunces:opsz,wght@9..144,500;9..144,700&display=swap');

:root {
  --bg-top: #e8eef3;
  --bg-bottom: #f7fafc;
  --text: #15232f;
  --muted: #536575;
  --brand-900: #0f2c3b;
  --brand-700: #145370;
  --brand-500: #1d7a8f;
  --surface: #ffffff;
  --surface-soft: #f2f7fb;
  --border: #d2dde7;
  --success-bg: #d1fae5;
  --success-text: #0f5132;
  --error-bg: #fee2e2;
  --error-text: #7f1d1d;
  --shadow: 0 18px 40px rgba(15, 44, 59, 0.1);
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  color: var(--text);
  font-family: 'Manrope', 'Segoe UI', sans-serif;
  background:
    radial-gradient(circle at 8% 10%, rgba(20, 83, 112, 0.12), transparent 30%),
    radial-gradient(circle at 90% 0%, rgba(29, 122, 143, 0.12), transparent 25%),
    linear-gradient(180deg, var(--bg-top) 0%, var(--bg-bottom) 42%, #eef3f7 100%);
  line-height: 1.65;
}

a {
  color: var(--brand-700);
  text-decoration: none;
}

a:hover,
a:focus-visible {
  text-decoration: underline;
}

.container {
  width: min(1140px, 92vw);
  margin: 0 auto;
}

header {
  background: linear-gradient(120deg, var(--brand-900), #0a3f56);
  color: #fff;
  border-bottom: 3px solid #58b0c6;
  box-shadow: 0 8px 22px rgba(0, 0, 0, 0.18);
}

.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  padding: 18px 0;
}

.brand {
  font-family: 'Fraunces', Georgia, serif;
  font-size: 1.55rem;
  font-weight: 700;
  letter-spacing: 0.02em;
}

nav {
  display: flex;
  flex-wrap: wrap;
  gap: 14px;
}

nav a {
  color: #dcedf5;
  font-weight: 600;
  padding: 6px 10px;
  border-radius: 8px;
}

nav a:hover,
nav a:focus-visible {
  color: #fff;
  background: rgba(255, 255, 255, 0.14);
}

.hero {
  padding: 58px 0 30px;
}

.eyebrow {
  margin: 0 0 8px;
  text-transform: uppercase;
  letter-spacing: 0.09em;
  color: var(--brand-700);
  font-size: 0.82rem;
  font-weight: 800;
}

.hero h1 {
  margin: 0;
  max-width: 15ch;
  font-size: clamp(2rem, 5.2vw, 3rem);
  line-height: 1.15;
  font-family: 'Fraunces', Georgia, serif;
}

.hero p {
  max-width: 70ch;
  color: var(--muted);
  margin: 14px 0 0;
}

.section {
  padding: 30px 0;
}

.section h2 {
  margin: 0 0 16px;
  font-size: clamp(1.25rem, 2.3vw, 1.65rem);
}

.stats-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 16px;
}

.metric-card,
.clock-card,
.card,
form,
table {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 16px;
  box-shadow: var(--shadow);
}

.metric-card,
.clock-card {
  padding: 18px;
}

.metric-card h2,
.clock-card h2 {
  margin: 0;
  font-size: 0.95rem;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--muted);
}

.metric-value {
  margin: 9px 0 0;
  font-size: clamp(1.6rem, 3vw, 2rem);
  font-weight: 800;
  color: var(--brand-900);
}

.clock-card {
  display: grid;
  place-items: center;
  text-align: center;
  background: linear-gradient(180deg, #ffffff 0%, #f4fbff 100%);
}

.wall-clock {
  position: relative;
  width: 170px;
  height: 170px;
  border-radius: 50%;
  border: 8px solid #d7e6f0;
  margin: 10px 0 14px;
  background:
    radial-gradient(circle at center, #f6fcff 0%, #eef7fc 65%, #e6f1f8 100%);
}

.clock-hand {
  position: absolute;
  left: 50%;
  bottom: 50%;
  transform-origin: bottom center;
  transform: translateX(-50%) rotate(0deg);
  border-radius: 10px;
}

.clock-hand.hour {
  width: 6px;
  height: 45px;
  background: #1c3f53;
}

.clock-hand.minute {
  width: 4px;
  height: 62px;
  background: #2c5c74;
}

.clock-hand.second {
  width: 2px;
  height: 68px;
  background: #be123c;
}

.clock-center {
  position: absolute;
  top: 50%;
  left: 50%;
  width: 12px;
  height: 12px;
  background: #1c3f53;
  border: 2px solid #fff;
  border-radius: 50%;
  transform: translate(-50%, -50%);
}

.clock-text {
  margin: 0;
  font-size: 1.15rem;
  font-weight: 700;
}

.cards {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: 16px;
}

.cards-portfolio {
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
}

.card {
  padding: 18px;
}

.card h3 {
  margin-top: 0;
  margin-bottom: 8px;
  font-size: 1.08rem;
}

.portfolio-image {
  width: 100%;
  aspect-ratio: 16 / 10;
  object-fit: cover;
  border-radius: 12px;
  border: 1px solid var(--border);
  margin-bottom: 12px;
}

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

.contact-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px;
}

form {
  padding: 18px;
}

.form-field {
  margin-bottom: 12px;
}

label {
  display: block;
  font-weight: 700;
  margin-bottom: 6px;
}

input,
textarea,
select {
  width: 100%;
  border: 1px solid #bfd0de;
  border-radius: 12px;
  padding: 10px 12px;
  margin-bottom: 6px;
  font: inherit;
  color: var(--text);
  background: #fafdff;
}

textarea {
  min-height: 115px;
  resize: vertical;
}

input[type='checkbox'] {
  width: auto;
  margin-right: 8px;
}

button {
  border: none;
  border-radius: 11px;
  background: linear-gradient(135deg, var(--brand-700), var(--brand-500));
  color: #fff;
  font: inherit;
  font-weight: 700;
  padding: 10px 16px;
  cursor: pointer;
}

button:hover,
button:focus-visible {
  filter: brightness(1.05);
}

button:disabled {
  cursor: not-allowed;
  opacity: 0.6;
  filter: none;
}

.field-help {
  margin: 0;
  font-size: 0.86rem;
  color: #5d7181;
  transition: color 0.2s ease;
}

input:focus + .field-help,
textarea:focus + .field-help,
select:focus + .field-help {
  color: #12384b;
}

.notice {
  border-radius: 12px;
  padding: 11px 13px;
  margin: 10px 0 14px;
  border: 1px solid transparent;
}

.notice-success {
  color: var(--success-text);
  background: var(--success-bg);
  border-color: #a7f3d0;
}

.notice-error {
  color: var(--error-text);
  background: var(--error-bg);
  border-color: #fecaca;
}

.admin-top {
  margin: 18px 0;
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.admin-top a {
  background: #e5eef4;
  color: #12384b;
  border-radius: 10px;
  padding: 7px 12px;
  font-weight: 600;
}

.admin-top a:hover,
.admin-top a:focus-visible {
  background: #d2e2ee;
}

table {
  width: 100%;
  border-collapse: collapse;
  overflow: hidden;
  margin-top: 14px;
}

th,
td {
  text-align: left;
  vertical-align: top;
  padding: 10px;
  border-bottom: 1px solid var(--border);
}

th {
  background: var(--surface-soft);
  font-weight: 700;
}

.thumb {
  width: 68px;
  height: 44px;
  object-fit: cover;
  border-radius: 8px;
  border: 1px solid var(--border);
}

.code-block {
  border-radius: 12px;
  background: #0f2634;
  color: #dbecf4;
  padding: 14px;
  overflow-x: auto;
  font-family: 'Consolas', 'Courier New', monospace;
  font-size: 0.88rem;
}

footer {
  padding: 26px 0 38px;
  border-top: 1px solid var(--border);
  color: var(--muted);
  margin-top: 22px;
}

@media (max-width: 990px) {
  .stats-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 820px) {
  .header-inner {
    flex-direction: column;
    align-items: flex-start;
  }

  .contact-grid {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 560px) {
  .stats-grid {
    grid-template-columns: 1fr;
  }

  .hero {
    padding-top: 42px;
  }
}
