/* styles.css */
/* Yorokobi Social PWA - White Yorokobi Sushi Theme */
/* Modern UI Update: larger logo, cleaner buttons, softer cards, improved spacing */

:root {
  --color-white: #ffffff;
  --color-red: #e31b23;
  --color-red-dark: #c5161d;
  --color-red-soft: rgba(227, 27, 35, 0.08);
  --color-black: #111111;
  --color-gray: #555555;
  --color-gray-2: #737373;
  --color-light-gray: #f8f8f8;
  --color-soft-panel: #fbfbfb;
  --color-border: #e8e8e8;
  --color-border-dark: #d9d9d9;
  --color-success: #138a36;
  --color-warning: #b7791f;
  --color-error: #b91c1c;

  --radius-sm: 14px;
  --radius: 20px;
  --radius-lg: 28px;

  --shadow-soft: 0 10px 30px rgba(0, 0, 0, 0.06);
  --shadow-card: 0 16px 45px rgba(17, 17, 17, 0.08);
  --shadow-button: 0 10px 22px rgba(227, 27, 35, 0.22);
}

* {
  box-sizing: border-box;
}

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

body {
  margin: 0;
  min-height: 100vh;
  font-family: Arial, Helvetica, sans-serif;
  background: var(--color-white);
  color: var(--color-black);
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

a {
  color: inherit;
  text-decoration: none;
}

button,
input,
textarea,
select {
  font: inherit;
}

button {
  -webkit-tap-highlight-color: transparent;
}

.app-shell {
  width: 100%;
  min-height: 100vh;
  background:
    radial-gradient(circle at top left, rgba(227, 27, 35, 0.10), transparent 28%),
    radial-gradient(circle at top right, rgba(17, 17, 17, 0.035), transparent 22%),
    linear-gradient(180deg, #ffffff 0%, #ffffff 48%, #fafafa 100%);
}

.page {
  width: min(1140px, calc(100% - 32px));
  margin: 0 auto;
  padding: 26px 0 54px;
}

/* =========================================================
   Brand Header
   ========================================================= */

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

.brand-left {
  display: flex;
  align-items: center;
  gap: 20px;
}

.brand-logo {
  width: 108px;
  height: 108px;
  object-fit: contain;
  flex: 0 0 auto;
  filter: drop-shadow(0 8px 14px rgba(0, 0, 0, 0.10));
}

.brand-name {
  display: flex;
  flex-direction: column;
  line-height: 1.02;
}

.brand-title {
  font-size: clamp(34px, 5vw, 52px);
  font-weight: 900;
  letter-spacing: -1.5px;
}

.brand-slogan {
  margin-top: 7px;
  font-size: 16px;
  color: var(--color-red);
  font-weight: 800;
  letter-spacing: 0.2px;
}

.header-actions {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
  justify-content: flex-end;
}

/* =========================================================
   Cards / Layout
   ========================================================= */

.card {
  background: rgba(255, 255, 255, 0.94);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-card);
  padding: 24px;
}

.card-soft {
  background: var(--color-soft-panel);
  border: 1px solid var(--color-border);
  border-radius: var(--radius);
  padding: 20px;
}

.login-wrap {
  width: min(460px, calc(100% - 32px));
  margin: 0 auto;
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 34px 0;
}

.login-card {
  width: 100%;
}

.login-brand {
  text-align: center;
  margin-bottom: 26px;
}

.login-brand .brand-left {
  justify-content: center;
}

.login-brand .brand-logo {
  width: 122px;
  height: 122px;
}

.login-brand .brand-title {
  font-size: clamp(38px, 8vw, 48px);
}

.login-brand .brand-slogan {
  font-size: 16px;
}

h1,
h2,
h3 {
  margin: 0;
  color: var(--color-black);
}

h1 {
  font-size: clamp(30px, 4vw, 44px);
  letter-spacing: -0.8px;
  line-height: 1.08;
}

h2 {
  font-size: 25px;
  margin-bottom: 14px;
  letter-spacing: -0.3px;
}

h3 {
  font-size: 18px;
  margin-bottom: 8px;
}

p {
  margin: 0;
  color: var(--color-gray);
  line-height: 1.55;
}

.section {
  margin-top: 24px;
}

.grid {
  display: grid;
  gap: 18px;
}

.grid-2 {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.grid-3 {
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

/* =========================================================
   Forms
   ========================================================= */

.form {
  display: grid;
  gap: 17px;
}

.field {
  display: grid;
  gap: 8px;
}

label {
  font-weight: 800;
  color: var(--color-black);
}

input,
textarea,
select {
  width: 100%;
  border: 1px solid var(--color-border);
  background: var(--color-white);
  color: var(--color-black);
  border-radius: var(--radius-sm);
  padding: 14px 15px;
  outline: none;
  transition:
    border-color 0.18s ease,
    box-shadow 0.18s ease,
    background 0.18s ease;
}

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

input:hover,
textarea:hover,
select:hover {
  border-color: var(--color-border-dark);
}

input:focus,
textarea:focus,
select:focus {
  border-color: var(--color-red);
  box-shadow: 0 0 0 4px rgba(227, 27, 35, 0.12);
}

/* =========================================================
   Buttons
   ========================================================= */

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 48px;
  padding: 13px 20px;
  border: 0;
  border-radius: 999px;
  cursor: pointer;
  font-weight: 900;
  letter-spacing: -0.1px;
  transition:
    transform 0.18s ease,
    box-shadow 0.18s ease,
    background 0.18s ease,
    border-color 0.18s ease,
    opacity 0.18s ease;
  text-align: center;
  user-select: none;
}

.btn:hover {
  transform: translateY(-1px);
}

.btn:active {
  transform: translateY(0);
}

.btn:disabled {
  cursor: not-allowed;
  opacity: 0.55;
  transform: none;
  box-shadow: none;
}

.btn-primary {
  background: linear-gradient(180deg, var(--color-red), var(--color-red-dark));
  color: var(--color-white);
  box-shadow: var(--shadow-button);
}

.btn-primary:hover {
  background: linear-gradient(180deg, #ef2029, var(--color-red-dark));
  box-shadow: 0 14px 28px rgba(227, 27, 35, 0.28);
}

.btn-secondary {
  background: linear-gradient(180deg, #222222, var(--color-black));
  color: var(--color-white);
  box-shadow: 0 10px 22px rgba(17, 17, 17, 0.18);
}

.btn-light {
  background: rgba(255, 255, 255, 0.86);
  color: var(--color-black);
  border: 1px solid var(--color-border);
  box-shadow: 0 8px 18px rgba(17, 17, 17, 0.05);
}

.btn-light:hover {
  border-color: rgba(227, 27, 35, 0.32);
  background: var(--color-red-soft);
}

.btn-danger {
  background: linear-gradient(180deg, #c82323, var(--color-error));
  color: var(--color-white);
  box-shadow: 0 10px 22px rgba(185, 28, 28, 0.18);
}

.btn-full {
  width: 100%;
}

/* =========================================================
   Navigation Cards
   ========================================================= */

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

.nav-card {
  display: block;
  padding: 24px;
  border: 1px solid var(--color-border);
  border-radius: var(--radius-lg);
  background:
    linear-gradient(180deg, #ffffff 0%, #fdfdfd 100%);
  box-shadow: var(--shadow-soft);
  transition:
    transform 0.18s ease,
    border-color 0.18s ease,
    box-shadow 0.18s ease;
}

.nav-card:hover {
  transform: translateY(-3px);
  border-color: rgba(227, 27, 35, 0.45);
  box-shadow: 0 18px 40px rgba(17, 17, 17, 0.09);
}

.nav-card strong {
  display: block;
  font-size: 18px;
  margin-bottom: 7px;
  letter-spacing: -0.2px;
}

.nav-card span {
  color: var(--color-gray);
  font-size: 14px;
  line-height: 1.45;
}

/* =========================================================
   Platform Cards
   ========================================================= */

.platforms {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
}

.check-card {
  border: 1px solid var(--color-border);
  border-radius: var(--radius);
  padding: 15px;
  display: flex;
  gap: 11px;
  align-items: center;
  cursor: pointer;
  background: var(--color-white);
  box-shadow: 0 8px 18px rgba(17, 17, 17, 0.04);
  transition:
    border-color 0.18s ease,
    box-shadow 0.18s ease,
    background 0.18s ease,
    transform 0.18s ease;
}

.check-card:hover {
  border-color: rgba(227, 27, 35, 0.38);
  background: var(--color-red-soft);
  transform: translateY(-1px);
}

.check-card input {
  width: auto;
  accent-color: var(--color-red);
}

/* =========================================================
   Status Labels
   ========================================================= */

.status {
  display: inline-flex;
  align-items: center;
  border-radius: 999px;
  padding: 7px 11px;
  font-size: 13px;
  font-weight: 900;
}

.status-scheduled {
  background: rgba(183, 121, 31, 0.12);
  color: var(--color-warning);
}

.status-draft {
  background: rgba(85, 85, 85, 0.12);
  color: var(--color-gray);
}

.status-published {
  background: rgba(19, 138, 54, 0.12);
  color: var(--color-success);
}

.status-failed {
  background: rgba(185, 28, 28, 0.12);
  color: var(--color-error);
}

.status-cancelled {
  background: rgba(85, 85, 85, 0.12);
  color: var(--color-gray);
}

/* =========================================================
   Posts
   ========================================================= */

.post-list {
  display: grid;
  gap: 15px;
}

.post-item {
  display: grid;
  grid-template-columns: 104px 1fr auto;
  gap: 16px;
  align-items: center;
  border: 1px solid var(--color-border);
  border-radius: var(--radius-lg);
  padding: 16px;
  background: var(--color-white);
  box-shadow: 0 10px 26px rgba(17, 17, 17, 0.045);
}

.thumb {
  width: 104px;
  height: 104px;
  border-radius: 20px;
  background:
    linear-gradient(135deg, rgba(227, 27, 35, 0.08), rgba(17, 17, 17, 0.04));
  border: 1px solid var(--color-border);
  object-fit: cover;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--color-gray);
  font-size: 12px;
  text-align: center;
  padding: 8px;
}

.post-meta {
  display: grid;
  gap: 6px;
}

.post-title {
  font-weight: 900;
  letter-spacing: -0.2px;
}

.post-caption {
  color: var(--color-gray);
  line-height: 1.45;
  max-width: 640px;
}

.post-actions {
  display: flex;
  gap: 9px;
  flex-wrap: wrap;
  justify-content: flex-end;
}

/* =========================================================
   Alerts / Helpers
   ========================================================= */

.alert {
  border-radius: var(--radius-sm);
  padding: 14px 15px;
  margin-bottom: 17px;
  display: none;
  font-weight: 700;
}

.alert.show {
  display: block;
}

.alert-error {
  background: rgba(185, 28, 28, 0.1);
  color: var(--color-error);
  border: 1px solid rgba(185, 28, 28, 0.18);
}

.alert-success {
  background: rgba(19, 138, 54, 0.1);
  color: var(--color-success);
  border: 1px solid rgba(19, 138, 54, 0.18);
}

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

.small {
  font-size: 14px;
}

.hidden {
  display: none !important;
}

.footer-note {
  margin-top: 28px;
  text-align: center;
  color: var(--color-gray-2);
  font-size: 13px;
}

/* =========================================================
   Mobile
   ========================================================= */

@media (max-width: 820px) {
  .page {
    width: min(100% - 24px, 1140px);
    padding-top: 18px;
  }

  .brand-header {
    align-items: flex-start;
    flex-direction: column;
    padding-bottom: 24px;
  }

  .brand-left {
    gap: 14px;
  }

  .brand-logo {
    width: 92px;
    height: 92px;
  }

  .brand-title {
    font-size: clamp(31px, 9vw, 43px);
  }

  .brand-slogan {
    font-size: 15px;
  }

  .header-actions {
    justify-content: flex-start;
    width: 100%;
  }

  .header-actions .btn {
    flex: 1 1 auto;
  }

  .grid-2,
  .grid-3,
  .nav-cards,
  .platforms {
    grid-template-columns: 1fr;
  }

  .card {
    padding: 20px;
    border-radius: 24px;
  }

  .post-item {
    grid-template-columns: 1fr;
  }

  .thumb {
    width: 100%;
    height: 190px;
  }

  .post-actions {
    justify-content: flex-start;
  }

  .post-actions .btn {
    flex: 1 1 auto;
  }
}

@media (max-width: 460px) {
  .brand-logo {
    width: 84px;
    height: 84px;
  }

  .brand-title {
    font-size: 31px;
  }

  .login-brand .brand-logo {
    width: 112px;
    height: 112px;
  }

  .btn {
    width: 100%;
  }
}
