/* ── Pet Health Plus – Prescription Ordering Plugin ── */

:root {
  --php-blue:       #1a5fa8;
  --php-blue-dark:  #134880;
  --php-blue-light: #e8f0fb;
  --php-grey:       #6b7280;
  --php-grey-light: #f3f4f6;
  --php-border:     #d1d5db;
  --php-text:       #111827;
  --php-success:    #16a34a;
  --php-error:      #dc2626;
  --php-radius:     10px;
  --php-shadow:     0 2px 12px rgba(0,0,0,.08);
}

#php-order-wrap *,
#php-order-wrap *::before,
#php-order-wrap *::after { box-sizing: border-box; margin: 0; padding: 0; }

#php-order-wrap {
  font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  color: var(--php-text);
  max-width: 1400px;
  margin: 0 auto;
  padding: 24px 16px 48px;
}

/* ── Progress bar ── */
.php-progress {
  display: flex;
  align-items: center;
  gap: 4px;
  margin-bottom: 36px;
  overflow-x: auto;
  padding-bottom: 4px;
}
.php-step {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 4px;
  flex: 1;
  min-width: 60px;
  opacity: .45;
  transition: opacity .25s;
}
.php-step.active  { opacity: 1; }
.php-step.done    { opacity: .75; }
.php-step-num {
  width: 34px; height: 34px;
  border-radius: 50%;
  border: 2px solid var(--php-border);
  display: grid; place-items: center;
  font-weight: 700; font-size: .85rem;
  background: #fff;
  transition: background .25s, border-color .25s, color .25s;
}
.php-step.active .php-step-num {
  background: var(--php-blue);
  border-color: var(--php-blue);
  color: #fff;
}
.php-step.done .php-step-num {
  background: var(--php-blue-light);
  border-color: var(--php-blue);
  color: var(--php-blue);
}
.php-step span { font-size: .72rem; text-align: center; white-space: nowrap; }
.php-step-arrow { color: var(--php-border); font-size: 1.2rem; flex-shrink: 0; }

/* ── Panels ── */
.php-panel { display: none; }
.php-panel.active { display: block; animation: phpFadeIn .3s ease; }
@keyframes phpFadeIn { from { opacity:0; transform:translateY(8px); } to { opacity:1; transform:none; } }

.php-panel h2 {
  font-size: 1.45rem;
  font-weight: 700;
  margin-bottom: 8px;
  color: var(--php-blue-dark);
}
.php-panel > p { color: var(--php-grey); margin-bottom: 24px; line-height: 1.6; }

/* ── Buttons ── */
.php-btn {
  display: inline-block;
  padding: 11px 26px;
  border-radius: var(--php-radius);
  font-size: .95rem;
  font-weight: 600;
  cursor: pointer;
  border: 2px solid transparent;
  transition: background .2s, transform .1s;
  text-decoration: none;
}
.php-btn:active { transform: scale(.97); }
.php-btn-primary {
  background: var(--php-blue);
  color: #fff;
  border-color: var(--php-blue);
}
.php-btn-primary:hover { background: var(--php-blue-dark); border-color: var(--php-blue-dark); }
.php-btn-primary:disabled { opacity: .5; cursor: not-allowed; }
.php-btn-secondary {
  background: #fff;
  color: var(--php-blue);
  border-color: var(--php-blue);
}
.php-btn-secondary:hover { background: var(--php-blue-light); }
.php-btn-select {
  margin-top: 12px;
  width: 100%;
  background: var(--php-blue);
  color: #fff;
  border-color: var(--php-blue);
}
.php-btn-select:hover { background: var(--php-blue-dark); }

/* ── Notice ── */
#php-notice {
  padding: 0;
  margin-bottom: 0;
  border-radius: var(--php-radius);
  font-size: .9rem;
  font-weight: 500;
  overflow: hidden;
  max-height: 0;
  transition: max-height .3s, padding .3s, margin .3s;
}
#php-notice.show {
  max-height: 80px;
  padding: 12px 18px;
  margin-bottom: 20px;
}
#php-notice.error   { background: #fef2f2; color: var(--php-error);   border: 1px solid #fecaca; }
#php-notice.success { background: #f0fdf4; color: var(--php-success); border: 1px solid #bbf7d0; }

/* ── Forms ── */
.php-field { display: flex; flex-direction: column; gap: 5px; margin-bottom: 16px; }
.php-field label { font-size: .88rem; font-weight: 600; }
.php-field small  { font-weight: 400; color: var(--php-grey); }
.php-field input[type="text"],
.php-field input[type="email"],
.php-field input[type="tel"],
.php-field input[type="password"],
.php-field textarea {
  padding: 10px 14px;
  border: 1px solid var(--php-border);
  border-radius: var(--php-radius);
  font-size: .95rem;
  width: 100%;
  transition: border-color .2s, box-shadow .2s;
}
.php-field input:focus,
.php-field textarea:focus {
  outline: none;
  border-color: var(--php-blue);
  box-shadow: 0 0 0 3px rgba(26,95,168,.15);
}
.php-field-row { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }
.php-field-check { flex-direction: row; align-items: flex-start; gap: 10px; }
.php-field-check input { margin-top: 3px; width: auto; }
.php-forgot { font-size: .83rem; margin: -8px 0 16px; }
.php-forgot a { color: var(--php-blue); }

/* ── Auth tabs ── */
.php-auth-tabs { display: flex; gap: 0; margin-bottom: 28px; border-bottom: 2px solid var(--php-border); }
.php-tab {
  padding: 10px 22px;
  background: none;
  border: none;
  font-size: .95rem;
  font-weight: 600;
  color: var(--php-grey);
  cursor: pointer;
  border-bottom: 2px solid transparent;
  margin-bottom: -2px;
  transition: color .2s, border-color .2s;
}
.php-tab.active { color: var(--php-blue); border-color: var(--php-blue); }
.php-tab-content { display: none; }
.php-tab-content.active { display: block; }

/* ── Product grid ── */
.php-product-grid{
display:grid;
grid-template-columns:repeat(auto-fit,minmax(320px,1fr));
gap:32px;
margin-top:30px;
}
.php-product-card{
background:#fff;
border:1px solid #e5e7eb;
border-radius:20px;
overflow:hidden;
box-shadow:0 8px 25px rgba(0,0,0,.08);
transition:all .3s ease;
display:flex;
flex-direction:column;
}
.php-product-card:hover { box-shadow: 0 4px 20px rgba(26,95,168,.15); transform: translateY(-2px); }
.php-product-icon { font-size: 2rem; margin-bottom: 10px; }
.php-product-card h3 { font-size: 1rem; font-weight: 700; margin-bottom: 4px; }
.php-product-type { font-size: .8rem; color: var(--php-grey); margin-bottom: 8px; }
.php-product-price { font-size: 1.1rem; font-weight: 700; color: var(--php-blue); margin-top: auto; }

/* ── Patient list ── */
.php-patient-list { display: flex; flex-direction: column; gap: 10px; margin-bottom: 20px; }
.php-patient-card {
  display: flex; align-items: center; justify-content: space-between;
  border: 2px solid var(--php-border);
  border-radius: var(--php-radius);
  padding: 14px 18px;
  cursor: pointer;
  transition: border-color .2s, background .2s;
}
.php-patient-card:hover,
.php-patient-card.selected { border-color: var(--php-blue); background: var(--php-blue-light); }
.php-patient-card h4 { font-weight: 700; margin-bottom: 2px; }
.php-patient-card p  { font-size: .82rem; color: var(--php-grey); }
.php-patient-check { font-size: 1.2rem; color: var(--php-blue); display: none; }
.php-patient-card.selected .php-patient-check { display: block; }

details#php-new-patient-form {
  border: 1px solid var(--php-border);
  border-radius: var(--php-radius);
  padding: 0;
  margin-top: 8px;
  overflow: hidden;
}
details#php-new-patient-form summary {
  padding: 12px 18px;
  cursor: pointer;
  font-weight: 600;
  color: var(--php-blue);
  background: var(--php-grey-light);
  user-select: none;
}
details#php-new-patient-form[open] summary { border-bottom: 1px solid var(--php-border); }
details#php-new-patient-form > *:not(summary) { padding: 18px; }

/* ── Upload area ── */
.php-upload-area {
  border: 2px dashed var(--php-border);
  border-radius: var(--php-radius);
  padding: 40px 24px;
  text-align: center;
  margin-bottom: 16px;
  transition: border-color .2s, background .2s;
}
.php-upload-area.dragging { border-color: var(--php-blue); background: var(--php-blue-light); }
.php-upload-icon { font-size: 2.5rem; margin-bottom: 12px; }
.php-upload-area p { color: var(--php-grey); margin-bottom: 12px; }
.php-file-name { font-size: .85rem; color: var(--php-blue); font-weight: 600; margin-top: 10px; min-height: 1.2em; }
.php-visually-hidden { position: absolute; width: 1px; height: 1px; clip: rect(0 0 0 0); overflow: hidden; }

/* ── Summary ── */
.php-summary {
  border: 1px solid var(--php-border);
  border-radius: var(--php-radius);
  overflow: hidden;
  margin-bottom: 20px;
}
.php-summary-row {
  display: flex; gap: 12px;
  padding: 13px 18px;
  border-bottom: 1px solid var(--php-border);
}
.php-summary-row:last-child { border-bottom: none; }
.php-summary-label { font-weight: 600; min-width: 140px; color: var(--php-grey); font-size: .88rem; }
.php-summary-value { flex: 1; font-size: .92rem; }

/* ── Confirm ── */
#php-panel-confirm { text-align: center; padding: 40px 0; }
.php-confirm-icon { font-size: 3.5rem; margin-bottom: 20px; }
#php-panel-confirm h2 { font-size: 1.8rem; margin-bottom: 12px; }
#php-panel-confirm p  { color: var(--php-grey); line-height: 1.7; }

.php-note { font-size: .83rem; color: var(--php-grey); margin-bottom: 18px; line-height: 1.5; }
.php-loading { color: var(--php-grey); font-size: .9rem; }

/* PROFESSIONAL UI UPGRADE */

#php-order-wrap{
    max-width:1400px;
    margin:40px auto;
    padding:30px;
    background:#fff;
    border-radius:16px;
    box-shadow:0 10px 30px rgba(0,0,0,.08);
}

.php-progress{
    background:#f8fafc;
    padding:20px;
    border-radius:12px;
    margin-bottom:30px;
}

/*.php-product-card{
    padding:0;
    overflow:hidden;
    border:1px solid #e5e7eb;
    border-radius:16px;
    box-shadow:0 4px 16px rgba(0,0,0,.08);
}

.php-product-card img{
    width:100%;
    height:240px;
    object-fit:contain;
    background:#fff;
}

.php-product-card h3{
    padding:16px 16px 6px;
}*/

.php-product-type,
.php-product-price{
    padding:0 16px;
}

.php-btn-select{
    margin:16px;
    width:calc(100% - 32px);
    border-radius:10px;
}

.php-panel h2{
    font-size:32px;
    margin-bottom:10px;
}

/* CARD */

/*.php-product-card{
    background:#fff;
    border-radius:15px;
    overflow:hidden;
    text-align:center;
    transition:.3s;
}

.php-product-card:hover{
    transform:translateY(-5px);
}*/

/* IMAGE */

.php-product-image{
    background:#fff;
    border:1px solid #eee;
    border-radius:12px;
    padding:20px;
    margin-bottom:20px;
}

.php-product-image img{
    width:100%;
    height:260px;
    object-fit:contain;
    display:block;
}

/* CONTENT */

.php-product-content{
    padding:0 10px 15px;
}

.php-product-title{
    font-size:20px;
    font-weight:700;
    line-height:1.3;
    margin-bottom:10px;
    color:#111827;
}

/* RATING */

.php-product-rating{
    margin-bottom:10px;
}

.php-product-rating .star-rating{
    margin:0 auto;
}

/* PRICE */

.php-product-price{
    font-size:20px;
    font-weight:700;
    color:#111827;
    margin-bottom:12px;
}

/* DESCRIPTION */

.php-product-desc{
    font-size:16px;
    color:#666;
    line-height:1.5;
    min-height:50px;
    margin-bottom:20px;
}

/* BUTTON */

.php-btn-select{
    background:#007c99;
    color:#fff;
    border:none;
    border-radius:40px;
    padding:14px 30px;
    font-size:16px;
    font-weight:600;
    cursor:pointer;
    min-width:180px;
    transition:.3s;
}

.php-btn-select:hover{
    background:#00657e;
}

/* =====================================================
   AUTH WRAPPER
===================================================== */

.php-auth-wrapper{
    max-width:780px;
    margin:0 auto;
}

/* =====================================================
   TABS
===================================================== */

.php-auth-tabs{
    display:flex;
    gap:12px;
    margin-bottom:25px;
}

.php-tab{
    flex:1;
    border:none;
    background:#f4f6f8;
    color:#64748b;
    padding:16px;
    font-size:15px;
    font-weight:600;
    border-radius:14px;
    cursor:pointer;
    transition:all .3s ease;
}

.php-tab:hover{
    background:#e8eef6;
}

.php-tab.active{
    background:#1a5fa8;
    color:#fff;
    box-shadow:0 8px 20px rgba(26,95,168,.25);
}

/* =====================================================
   CARD
===================================================== */

.php-auth-card{
    background:#fff;
    border-radius:20px;
    padding:40px;
    border:1px solid #e5e7eb;
    box-shadow:0 10px 35px rgba(0,0,0,.08);
}

/* =====================================================
   HEADING
===================================================== */

.php-auth-card h2{
    font-size:36px;
    font-weight:700;
    color:#134880;
    margin:0 0 10px;
}

.php-auth-subtitle{
    color:#6b7280;
    font-size:15px;
    margin-bottom:30px;
}

/* =====================================================
   FIELD ROW
===================================================== */

.php-field-row{
    display:grid;
    grid-template-columns:1fr 1fr;
    gap:20px;
}

/* =====================================================
   FIELDS
===================================================== */

.php-field{
    margin-bottom:20px;
}

.php-field label{
    display:block;
    margin-bottom:8px;
    font-size:14px;
    font-weight:600;
    color:#374151;
}

.php-field label span{
    color:#dc2626;
}

.php-field small{
    color:#6b7280;
    font-weight:400;
}

.php-field input,
.php-field textarea{
    width:100%;
    border:1px solid #d1d5db;
    border-radius:12px;
    padding:14px 16px;
    font-size:15px;
    background:#fff;
    transition:.3s;
}

.php-field textarea{
    resize:vertical;
    min-height:100px;
}

.php-field input:focus,
.php-field textarea:focus{
    outline:none;
    border-color:#1a5fa8;
    box-shadow:0 0 0 4px rgba(26,95,168,.12);
}

/* =====================================================
   FORGOT PASSWORD
===================================================== */

.php-forgot{
    margin:5px 0 25px;
}

.php-forgot a{
    color:#1a5fa8;
    text-decoration:none;
    font-size:14px;
}

.php-forgot a:hover{
    text-decoration:underline;
}

/* =====================================================
   PRIVACY CHECKBOX
===================================================== */

.php-field-check{
    display:flex;
    align-items:flex-start;
    gap:12px;
    margin:20px 0 30px;
}

.php-field-check input[type="checkbox"]{
    width:18px;
    height:18px;
    margin-top:3px;
    flex-shrink:0;
}

.php-field-check label{
    margin:0;
    font-size:14px;
    line-height:1.6;
    color:#4b5563;
}

.php-field-check a{
    color:#1a5fa8;
    text-decoration:none;
}

.php-field-check a:hover{
    text-decoration:underline;
}

/* =====================================================
   BUTTONS
===================================================== */

#php-do-login,
#php-do-register,
#php-skip-auth{
    width:100%;
    border:none;
    background:#1a5fa8;
    color:#fff;
    border-radius:12px;
    padding:16px 24px;
    font-size:16px;
    font-weight:600;
    cursor:pointer;
    transition:.3s;
}

#php-do-login:hover,
#php-do-register:hover,
#php-skip-auth:hover{
    background:#134880;
    transform:translateY(-1px);
}

/* =====================================================
   LOGGED IN STATE
===================================================== */

/* ======================================
   AUTH SECTION FIX
====================================== */

#php-panel-2{
    max-width:800px;
    margin:0 auto;
}

.php-auth-wrapper{
    position:relative;
}

.php-auth-tabs{
    display:flex !important;
    gap:0;
    margin:0 0 -1px 0;
    position:relative;
    z-index:10;
}

.php-tab{
    flex:1;
    padding:16px 20px !important;
    border:none !important;
    background:#f4f6f8 !important;
    color:#6b7280 !important;
    font-size:16px !important;
    font-weight:600 !important;
    cursor:pointer;
    transition:.3s;
}

.php-tab:first-child{
    border-radius:16px 0 0 0;
}

.php-tab:last-child{
    border-radius:0 16px 0 0;
}

.php-tab.active{
    background:#1a5fa8 !important;
    color:#fff !important;
}

/* Hide inactive tab */

.php-tab-content{
    display:none;
}

.php-tab-content.active{
    display:block;
}

/* Main card */

.php-auth-card{
    background:#fff !important;
    border:1px solid #e5e7eb !important;
    border-radius:0 0 16px 16px !important;
    padding:35px !important;
    box-shadow:0 8px 30px rgba(0,0,0,.08) !important;
}

/* Heading */

.php-auth-card h2{
    margin:0 0 25px !important;
    font-size:42px !important;
    line-height:1.1 !important;
    font-weight:700 !important;
    color:#134880 !important;
}

/* Fields */

.php-field{
    margin-bottom:20px !important;
}

.php-field label{
    display:block !important;
    margin-bottom:8px !important;
    font-size:15px !important;
    font-weight:600 !important;
    color:#374151 !important;
}

/* Inputs */

.php-field input,
.php-field textarea{
    width:100% !important;
    border:1px solid #d1d5db !important;
    border-radius:10px !important;
    padding:14px 16px !important;
    font-size:15px !important;
    background:#fff !important;
    box-sizing:border-box;
}

.php-field textarea{
    min-height:120px;
}

#php-order-wrap{
    max-width:1400px;
    width:100%;
    margin:40px auto;
    padding:30px;
}

.php-panel{
    width:100%;
    max-width:none;
}

.php-panel.active{
    width:100%;
}

/* Two columns */

.php-field-row{
    display:grid !important;
    grid-template-columns:1fr 1fr !important;
    gap:20px !important;
}

/* Forgot */

.php-forgot{
    margin:0 0 20px !important;
}

/* Checkbox */

.php-field-check{
    display:flex !important;
    align-items:flex-start !important;
    gap:10px !important;
    margin:20px 0 !important;
}

.php-field-check input[type="checkbox"]{
    width:18px !important;
    height:18px !important;
    margin-top:3px !important;
    flex:none;
}

.php-field-check label{
    margin:0 !important;
    line-height:1.5;
}

/* Buttons */

#php-do-login,
#php-do-register{
    width:100% !important;
    padding:16px !important;
    background:#1a5fa8 !important;
    color:#fff !important;
    border:none !important;
    border-radius:10px !important;
    font-size:16px !important;
    font-weight:600 !important;
    cursor:pointer;
}

/* Mobile */

@media(max-width:768px){

    .php-field-row{
        grid-template-columns:1fr !important;
    }

    .php-auth-card{
        padding:25px !important;
    }

    .php-auth-card h2{
        font-size:32px !important;
    }
}

@media(max-width:768px){
    #php-order-wrap{
        padding:15px;
    }
    .php-field-row{
        grid-template-columns:1fr;
    }
}

@media (max-width: 520px) {
  .php-field-row { grid-template-columns: 1fr; }
  .php-product-grid { grid-template-columns: 1fr; }
  .php-step span { display: none; }
}
