/* TEMA Photography — owner studio */
.st { max-width: 1500px; margin: 0 auto; padding: calc(var(--nav-h) + 40px) var(--pad) 80px; min-height: 100vh; }
.st-lock { display: grid; justify-items: center; text-align: center; gap: 12px; padding: 12vh 0; }
.st-lock img { width: 90px; filter: drop-shadow(0 0 24px rgba(255,77,138,.4)); }
.st-lock h1 { font-size: clamp(34px, 4vw, 56px); }
.st-lock p { color: var(--muted); }

.st-head { display: flex; justify-content: space-between; align-items: flex-end; gap: 20px; flex-wrap: wrap; margin-bottom: 28px; }
.st-title { font-size: clamp(38px, 4.6vw, 66px); line-height: 1.35; }
.st-sub { color: var(--muted); margin: 0; }
.st-head__acts { display: flex; gap: 10px; flex-wrap: wrap; }
.st-head__acts .btn { padding: 13px 22px; }

.st-stats { display: grid; grid-template-columns: repeat(4, 1fr); gap: 14px; margin-bottom: 22px; }
.st-stat { background: var(--paper); border: 1px solid var(--line); border-radius: 4px; padding: 18px 20px; display: grid; gap: 2px; animation: rcIn .8s var(--ease) both; animation-delay: calc(var(--i) * 80ms); }
.st-stat span { color: var(--ink-2); font-size: 14px; }
.st-stat b { font-family: var(--f-it); font-weight: 500; font-size: 52px; line-height: 1.05; color: var(--ink); }
.st-stat small { color: var(--muted); font-size: 12.5px; }
.st-stat--new { background: var(--rose); color: #fff; border-color: transparent; }
.st-stat--new span, .st-stat--new small, .st-stat--new b { color: #fff; }

.st-grid { display: grid; grid-template-columns: 1.05fr 1fr; gap: 22px; align-items: start; }
.st-card { background: var(--paper); border: 1px solid var(--line); border-radius: 4px; padding: clamp(18px, 2vw, 28px); }
.st-cal__head { display: flex; align-items: center; justify-content: space-between; margin-bottom: 14px; }
.st-cal__head h2 { font-size: 22px; }
.st-ic { width: 40px; height: 40px; border-radius: 50%; display: grid; place-items: center; box-shadow: inset 0 0 0 1px var(--line); transition: background .3s, color .3s; }
.st-ic:hover { background: var(--ink); color: #fff; }
.st-ic svg { width: 18px; fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }
.st-cal__dow, .st-cal__days { display: grid; grid-template-columns: repeat(7, 1fr); gap: 6px; }
.st-cal__dow span { text-align: center; font-size: 12.5px; color: var(--muted); padding-bottom: 6px; }
.st-day { position: relative; min-height: 76px; border-radius: 4px; padding: 6px 7px; text-align: right; background: var(--cream); display: flex; flex-direction: column; gap: 3px; transition: background .3s, box-shadow .3s; overflow: hidden; }
.st-day b { font-family: var(--f-it); font-weight: 500; font-size: 20px; line-height: 1; }
.st-day em { font-style: normal; font-size: 11px; color: var(--ink-2); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.st-day--pad { background: transparent; }
.st-day.is-past { opacity: .55; }
.st-day.has { background: var(--blush); }
.st-day:hover { box-shadow: inset 0 0 0 1.5px var(--rose); }
.st-day.is-today { box-shadow: inset 0 0 0 1.5px var(--ink); }
.st-day.is-today b { color: var(--rose); }
.st-day.is-sel { background: var(--ink); color: #fff; }
.st-day.is-sel em { color: rgba(255,255,255,.8); }
.st-dots { display: flex; gap: 3px; }
.st-dots i, .st-cal__legend i { width: 7px; height: 7px; border-radius: 50%; display: inline-block; }
.s-new { --c: var(--rose); } .s-confirmed { --c: #1f9d55; } .s-done { --c: #8C7C77; } .s-cancelled { --c: #c9b9b2; }
.st-dots i, .st-cal__legend i { background: var(--c); }
.st-cal__legend { display: flex; gap: 16px; flex-wrap: wrap; margin-top: 14px; font-size: 12.5px; color: var(--muted); }
.st-cal__legend span { display: inline-flex; align-items: center; gap: 6px; }

.st-list__head { display: flex; justify-content: space-between; align-items: center; gap: 12px; flex-wrap: wrap; margin-bottom: 16px; }
.st-list__head h2 { font-size: 22px; }
.st-tabs { display: flex; gap: 4px; padding: 4px; background: var(--cream); border-radius: 30px; }
.st-tabs button { padding: 7px 14px; border-radius: 30px; font-size: 13.5px; font-family: var(--f-head); color: var(--ink-2); transition: all .3s; }
.st-tabs button.is-on { background: var(--ink); color: #fff; }
.st-items { display: grid; gap: 10px; max-height: 72vh; overflow-y: auto; padding-left: 4px; }
.st-empty { color: var(--muted); text-align: center; padding: 40px 0; }
.st-item { display: grid; grid-template-columns: 74px 1fr; gap: 14px; padding: 14px; border-radius: 4px; background: var(--cream); border-right: 3px solid var(--c); animation: rcIn .7s var(--ease) both; animation-delay: calc(var(--i) * 50ms); }
.st-item.is-flash { animation: flashIn 1.6s ease 2; }
@keyframes flashIn { 50% { box-shadow: 0 0 0 3px var(--rose); } }
.st-item__date { display: grid; justify-items: center; align-content: center; background: var(--paper); border-radius: 4px; padding: 8px 4px; line-height: 1.15; }
.st-item__date b { font-family: var(--f-it); font-weight: 500; font-size: 32px; color: var(--rose); }
.st-item__date span { font-size: 12.5px; font-family: var(--f-head); }
.st-item__date small { font-size: 11px; color: var(--muted); }
.st-item__top { display: flex; justify-content: space-between; align-items: center; gap: 8px; }
.st-item__top h3 { font-size: 17px; line-height: 1.5; }
.st-badge { font-size: 12px; padding: 2px 10px; border-radius: 20px; background: var(--c); color: #fff; white-space: nowrap; }
.st-item__meta { display: flex; flex-wrap: wrap; gap: 4px 14px; font-size: 13.5px; color: var(--ink-2); margin: 6px 0 0; }
.st-item__notes { font-size: 13.5px; color: var(--muted); margin: 6px 0 0; }
.st-item__acts { display: flex; flex-wrap: wrap; align-items: center; gap: 6px; margin-top: 10px; }
.st-item__acts a, .st-item__acts button, .st-item__acts select { font: inherit; font-size: 12.5px; padding: 5px 12px; border-radius: 20px; background: var(--paper); box-shadow: inset 0 0 0 1px var(--line); color: var(--ink); border: 0; transition: background .3s, color .3s; }
.st-item__acts a:hover, .st-item__acts button:hover { background: var(--ink); color: #fff; }
.st-item__acts .st-del:hover { background: var(--rose); }
.st-edit { grid-template-columns: 1fr; width: min(720px, 100%); }

/* ----- Packages manager ----- */
.st-pk { margin-top: 22px; scroll-margin-top: calc(var(--nav-h) + 20px); }
.st-pk .st-sub { font-size: 14px; }
.st-pk__grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(250px, 1fr)); gap: 14px; }
.st-pkc { display: grid; grid-template-rows: auto 1fr auto; background: var(--cream); border-radius: 4px; overflow: hidden; animation: rcIn .7s var(--ease) both; animation-delay: calc(var(--i) * 70ms); }
.st-pkc__img { position: relative; height: 150px; background: var(--sand) center / cover no-repeat; }
.st-pkc__img em { position: absolute; top: 10px; right: 10px; font-style: normal; font-size: 11.5px; background: var(--rose); color: #fff; padding: 2px 10px; border-radius: 20px; }
.st-pkc__img i { position: absolute; bottom: 10px; left: 10px; font-style: normal; font-size: 11.5px; background: rgba(0,0,0,.6); color: #fff; padding: 2px 10px; border-radius: 20px; }
.st-pkc__body { padding: 14px 16px 6px; }
.st-pkc__body h3 { font-size: 19px; line-height: 1.5; }
.st-pkc__body b { font-family: var(--f-it); font-weight: 500; font-size: 30px; color: var(--rose); }
.st-pkc__body small { color: var(--muted); margin-right: 4px; }
.st-pkc__body p { margin: 2px 0 0; font-size: 13px; color: var(--ink-2); }
.st-pkc__acts { display: flex; gap: 6px; padding: 10px 16px 16px; }
.st-pkc__acts button { flex: 1; font: inherit; font-size: 13px; padding: 7px 10px; border-radius: 20px; background: var(--paper); box-shadow: inset 0 0 0 1px var(--line); transition: background .3s, color .3s; }
.st-pkc__acts button:hover { background: var(--ink); color: #fff; }
.st-pkc__acts .st-del:hover { background: var(--rose); }
.st-pkedit { width: min(820px, 100%); }
.pk-img { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; margin-bottom: 18px; }
.pk-img__slot { display: grid; gap: 8px; font-size: 14px; color: var(--ink-2); }
.pk-img__box { position: relative; height: 150px; border-radius: 4px; background: var(--cream) center / cover no-repeat; border: 1px dashed var(--line); display: grid; place-items: center; color: var(--muted); font-size: 13px; }
.pk-img__box:empty::before { content: 'بدون صورة'; }
.pk-img__box.has-img:empty::before { content: none; }
.pk-img__slot[data-slot=poster] .pk-img__box { background-size: contain; }
.pk-img__box.is-busy::after { content: ''; width: 26px; height: 26px; border: 2.5px solid var(--line); border-top-color: var(--rose); border-radius: 50%; animation: spin .7s linear infinite; }
.pk-img__acts { display: flex; gap: 6px; }
.pk-img__acts > * { flex: 1; text-align: center; font: inherit; font-size: 13px; padding: 7px 10px; border-radius: 20px; background: var(--paper); box-shadow: inset 0 0 0 1px var(--line); cursor: pointer; transition: background .3s, color .3s; }
.pk-img__acts > *:hover { background: var(--ink); color: #fff; }
@media (max-width: 560px) { .pk-img { grid-template-columns: 1fr; } }

/* ----- Comments + assistant ----- */
.st-grid--2 { grid-template-columns: 1fr 1.15fr; margin-top: 22px; }
.st-cm, .st-ai { scroll-margin-top: calc(var(--nav-h) + 20px); }
.st-cmi { padding: 14px 16px; border-radius: 4px; background: var(--cream); border-right: 3px solid var(--rose); animation: rcIn .6s var(--ease) both; animation-delay: calc(var(--i) * 50ms); }
.st-cmi p { margin: 0 0 8px; font-size: 15px; line-height: 1.8; }
.st-cmi__foot { display: flex; flex-wrap: wrap; align-items: center; gap: 8px 12px; }
.st-cmi__foot b { font-family: var(--f-head); font-size: 14px; color: var(--rose); }
.st-cmi__foot small { color: var(--muted); font-size: 12px; }
.st-cmi__foot .st-item__acts { margin: 0 auto 0 0; }
.st-ai { display: flex; flex-direction: column; min-height: 520px; }
.st-ai__key-btn { font: inherit; font-size: 12.5px; padding: 6px 14px; border-radius: 20px; box-shadow: inset 0 0 0 1px var(--line); }
.st-ai__key { padding: 14px; background: var(--cream); border-radius: 4px; margin-bottom: 12px; font-size: 13.5px; color: var(--ink-2); }
.st-ai__key input { flex: 1; min-width: 200px; font: inherit; font-size: 14px; padding: 8px 12px; border: 1px solid var(--line); border-radius: 4px; background: var(--paper); }
.st-ai__log { flex: 1; display: flex; flex-direction: column; gap: 10px; overflow-y: auto; max-height: 58vh; padding: 6px 2px 12px; }
.ai-msg { max-width: 86%; padding: 12px 16px; border-radius: 16px; font-size: 15px; line-height: 1.8; animation: rcIn .5s var(--ease) both; }
.ai-msg--bot { align-self: flex-start; background: var(--cream); border-bottom-right-radius: 4px; }
.ai-msg--me { align-self: flex-end; background: var(--ink); color: #fff; border-bottom-left-radius: 4px; }
.ai-msg--act { align-self: flex-start; padding: 4px 12px; font-size: 12.5px; background: rgba(31,157,85,.12); color: #1f7a45; border-radius: 20px; }
.ai-msg em { color: var(--rose); font-style: normal; }
.ai-msg.is-typing { display: flex; gap: 5px; }
.ai-msg.is-typing i { width: 7px; height: 7px; border-radius: 50%; background: var(--rose); animation: typing 1.2s ease-in-out infinite; }
.ai-msg.is-typing i:nth-child(2) { animation-delay: .15s; } .ai-msg.is-typing i:nth-child(3) { animation-delay: .3s; }
@keyframes typing { 50% { transform: translateY(-5px); opacity: .4; } }
.st-ai__form { display: flex; gap: 8px; align-items: flex-end; border-top: 1px solid var(--line); padding-top: 12px; }
.st-ai__form textarea { flex: 1; font: inherit; font-size: 15px; padding: 10px 14px; border: 1px solid var(--line); border-radius: 4px; background: var(--cream); resize: none; }
.st-ai__form textarea:focus { outline: none; border-color: var(--rose); }
.st-ai__form .btn { padding: 13px 24px; }
@media (max-width: 1000px) { .st-grid--2 { grid-template-columns: 1fr; } }

@media (max-width: 1000px) {
  .st-grid { grid-template-columns: 1fr; }
  .st-stats { grid-template-columns: 1fr 1fr; }
}
@media (max-width: 560px) {
  .st-day { min-height: 52px; padding: 4px; }
  .st-day em { display: none; }
  .st-day b { font-size: 16px; }
  .st-item { grid-template-columns: 58px 1fr; }
}
