/* =========================================================
   PFCS – Front CSS (FINAL / Consolidated)
   ========================================================= */

:root{
  --pfcs-red:#f22a2d;
  --pfcs-red-dark:#d91f22;
  --pfcs-blue:#1f4c94;
  --pfcs-text:#222;
  --pfcs-muted:#666;
  --pfcs-border:#e9e9ee;

  --pfcs-radius:12px;
  --pfcs-shadow:0 4px 18px rgba(0,0,0,.06);

  --pfcs-adminbar-desktop:32px;
  --pfcs-adminbar-mobile:46px;

  --pfcs-bar-space-desktop:80px;
  --pfcs-bar-space-mobile:160px;
}

/* =========================================================
   Floating bar
   ========================================================= */
.pfcs-floating-bar{
  position:fixed;
  left:0;
  right:0;
  bottom:0;
  z-index:9999;
  background:#fff;
  box-shadow:0 -2px 10px rgba(0,0,0,.08);
  padding:10px 12px;
}

body.admin-bar .pfcs-floating-bar{ bottom:var(--pfcs-adminbar-desktop); }

@media (max-width:782px){
  body.admin-bar .pfcs-floating-bar{ bottom:var(--pfcs-adminbar-mobile); }
}

.pfcs-floating-inner{
  max-width:1200px;
  margin:0 auto;
  display:flex;
  align-items:center;
  justify-content:center;
  gap:12px;
  flex-wrap:wrap;
}

.pfcs-floating-title{
  font-weight:700;
  font-size:16px;
  color:var(--pfcs-text);
  margin:0;
}

/* Base button */
.pfcs-btn{
  display:inline-flex;
  align-items:center;
  justify-content:center;
  border-radius:999px;
  padding:9px 18px;
  border:2px solid var(--pfcs-red);
  background:var(--pfcs-red);
  color:#fff;
  font-weight:700;
  cursor:pointer;
  font-size:14px;
  line-height:1.2;
  text-decoration:none;
}

.pfcs-btn:hover{
  background:var(--pfcs-red-dark);
  border-color:var(--pfcs-red-dark);
}

/* Outline (Message) */
.pfcs-btn.pfcs-btn-message{
  background:#fff;
  color:var(--pfcs-red);
}

.pfcs-btn.pfcs-btn-message:hover{
  background:#ffe6e6;
}

/* Small utilities buttons */
.pfcs-btn-export,
.pfcs-btn-print{
  font-size:12px;
  padding:6px 10px;
  border-width:1px;
  background:#fff;
  color:var(--pfcs-red-dark);
  border-color:rgba(242,42,45,.55);
}

.pfcs-btn-export:hover,
.pfcs-btn-print:hover{
  background:#fff5f5;
  border-color:rgba(242,42,45,.75);
}

/* Body padding so footer isn't hidden */
body.pfcs-has-floating-bar{
  padding-bottom:var(--pfcs-bar-space-desktop);
}
body.admin-bar.pfcs-has-floating-bar{
  padding-bottom:calc(var(--pfcs-bar-space-desktop) + var(--pfcs-adminbar-desktop));
}

/* Back-to-top above bar */
body.pfcs-has-floating-bar #scrollUp,
body.pfcs-has-floating-bar .scrollup,
body.pfcs-has-floating-bar .scroll-up,
body.pfcs-has-floating-bar .scrollTop,
body.pfcs-has-floating-bar .rt-scroll-top,
body.pfcs-has-floating-bar .back-to-top,
body.pfcs-has-floating-bar .backtotop{
  bottom:calc(var(--pfcs-bar-space-desktop) + 30px) !important;
  z-index:10000 !important;
}

@media (max-width:768px){
  body.pfcs-has-floating-bar{
    padding-bottom:var(--pfcs-bar-space-mobile);
  }
  body.admin-bar.pfcs-has-floating-bar{
    padding-bottom:calc(var(--pfcs-bar-space-mobile) + var(--pfcs-adminbar-mobile));
  }

  body.pfcs-has-floating-bar #scrollUp,
  body.pfcs-has-floating-bar .scrollup,
  body.pfcs-has-floating-bar .scroll-up,
  body.pfcs-has-floating-bar .scrollTop,
  body.pfcs-has-floating-bar .rt-scroll-top,
  body.pfcs-has-floating-bar .back-to-top,
  body.pfcs-has-floating-bar .backtotop{
    bottom:calc(var(--pfcs-bar-space-mobile) + 30px) !important;
  }

  .pfcs-floating-bar{ padding:10px 12px 14px; }
  .pfcs-floating-inner{
    flex-direction:column;
    align-items:stretch;
    gap:8px;
  }
  .pfcs-floating-title{
    width:100%;
    text-align:center;
  }
  .pfcs-btn{
    width:100%;
    padding:10px 16px;
  }
}

/* =========================================================
   Modal (light)
   ========================================================= */
.pfcs-modal{
  position:fixed;
  inset:0;
  display:none;
  z-index:10000;
}
.pfcs-modal.pfcs-open{ display:block; }

.pfcs-modal-backdrop{
  position:absolute;
  inset:0;
  background:rgba(0,0,0,.45);
}

.pfcs-modal-dialog{
  position:relative;
  max-width:380px;
  margin:14vh auto;
  background:#fff;
  border-radius:var(--pfcs-radius);
  overflow:hidden;
  box-shadow:0 10px 30px rgba(0,0,0,.18);
}

@media (max-width:480px){
  .pfcs-modal-dialog{
    max-width:92vw;
    margin:12vh auto;
  }
}

.pfcs-modal-header{
  padding:16px 18px;
  border-bottom:1px solid #f0f0f0;
  font-weight:700;
  font-size:16px;
  color:var(--pfcs-text);
}

.pfcs-modal-body{ padding:18px; }

.pfcs-modal-footer{
  padding:12px 18px 16px;
  text-align:right;
  border-top:1px solid #f0f0f0;
}

.pfcs-phone-display{
  font-size:18px;
  font-weight:800;
  text-align:center;
  word-break:break-word;
}

.pfcs-btn-close{
  background:#fff;
  color:#333;
  border:1px solid #ddd;
}
.pfcs-btn-close:hover{
  background:#f6f6f6;
  border-color:#ccc;
}

/* =========================================================
   Dashboard vendor
   ========================================================= */
.pfcs-dashboard-wrapper{
  margin:24px 0 40px;
  padding:24px;
  border-radius:var(--pfcs-radius);
  background:#fff;
  border:1px solid #f3f3f3;
  box-shadow:var(--pfcs-shadow);
  font-size:15px;
  line-height:1.6;
}

@media (max-width:768px){
  .pfcs-dashboard-wrapper{ padding:18px 14px; }
}

.pfcs-section-title{
  font-size:20px;
  font-weight:700;
  margin:0 0 12px;
  color:var(--pfcs-text);
}

.pfcs-plan-info,
.pfcs-plan-status{
  margin:0 0 10px;
  font-size:14px;
  color:var(--pfcs-text);
}

.pfcs-plan-expiry,
.pfcs-plan-free-subtitle{
  margin:4px 0 0;
  font-size:13px;
  color:var(--pfcs-muted);
}

.pfcs-plan-expiry--highlight{
  margin-top:4px;
  font-size:15px;
  font-weight:700;
  color:#c62828;
}

/* Badges */
.pfcs-badge{
  display:inline-flex;
  align-items:center;
  padding:2px 10px;
  border-radius:999px;
  font-size:12px;
  font-weight:800;
  text-transform:uppercase;
  letter-spacing:.03em;
  border:1px solid var(--pfcs-border);
}

.pfcs-badge-free{
  background:#f5f5f5;
  color:#555;
}

.pfcs-badge-premium{
  background:var(--pfcs-red);
  border-color:var(--pfcs-red);
  color:#fff;
}

/* Notices */
.pfcs-dashboard-notice{
  background:#fff8e5;
  border-left:4px solid #ff9800;
  padding:14px 14px 18px;
  border-radius:8px;
  font-size:14px;
  line-height:1.5;
}

.pfcs-notice{
  margin:0 0 16px;
  padding:10px 14px;
  border-radius:8px;
  font-size:14px;
}
.pfcs-notice-success{
  background:#ecfdf3;
  border:1px solid rgba(34,197,94,.35);
  color:#166534;
}
.pfcs-notice-error{
  background:#fef2f2;
  border:1px solid rgba(239,68,68,.35);
  color:#b91c1c;
}
.pfcs-notice-info{
  background:#eff6ff;
  border:1px solid rgba(59,130,246,.35);
  color:#1d4ed8;
}

/* KPI */
.pfcs-kpi-row{
  display:flex;
  flex-wrap:wrap;
  gap:12px;
  margin:16px 0 12px;
}

.pfcs-kpi-box{
  flex:1 1 120px;
  padding:12px 14px;
  border-radius:10px;
  background:#fafafa;
  border:1px solid rgba(242,42,45,.15);
  text-align:center;
}

.pfcs-kpi-label{
  display:block;
  font-size:13px;
  color:var(--pfcs-muted);
  margin-bottom:4px;
}

.pfcs-kpi-value{
  font-size:20px;
  font-weight:800;
  color:#c62828;
}

/* Actions row */
.pfcs-actions-row{
  margin:10px 0 12px;
  display:flex;
  gap:8px;
  flex-wrap:wrap;
  justify-content:flex-end;
}

/* Tables */
.pfcs-table-wrapper{
  overflow-x:auto;
  margin-top:22px;
}

.pfcs-table{
  width:100%;
  border-collapse:collapse;
  font-size:13px;
}

.pfcs-table th,
.pfcs-table td{
  border:1px solid #eee;
  padding:6px 8px;
}

.pfcs-table th{
  background:#fafafa;
  text-align:left;
}

/* Toolbar (per-page + count) */
.pfcs-table-toolbar{
  display:flex;
  align-items:center;
  justify-content:space-between;
  margin-bottom:10px;
  gap:10px;
}

.pfcs-table-toolbar-left label{
  margin-right:6px;
  font-size:13px;
}

.pfcs-per-page-select{
  padding:4px 8px;
  border-radius:8px;
  border:1px solid #ddd;
  font-size:13px;
}

.pfcs-table-count{
  font-size:13px;
  color:var(--pfcs-muted);
}

@media (max-width:768px){
  .pfcs-table-toolbar{
    flex-direction:column;
    align-items:flex-start;
  }
}

/* Pagination */
.pfcs-pagination{ margin-top:14px; }

.pfcs-pagination .page-numbers{
  display:inline-flex;
  align-items:center;
  flex-wrap:wrap;
  gap:4px;
  padding-left:0;
  margin:0;
  list-style:none;
}

.pfcs-pagination .page-numbers li{ display:inline-block; }

.pfcs-pagination .page-numbers a,
.pfcs-pagination .page-numbers span{
  display:inline-block;
  padding:4px 9px;
  border-radius:999px;
  border:1px solid transparent;
  font-size:13px;
}

.pfcs-pagination .page-numbers .current{
  background:var(--pfcs-red);
  border-color:var(--pfcs-red);
  color:#fff;
}

.pfcs-pagination .page-numbers a:hover{
  border-color:#e0e0e0;
}

/* =========================================================
   Free plan box + request form
   ========================================================= */
.pfcs-account-plan{
  margin:12px 0 26px;
  display:flex;
  align-items:center;
  gap:10px;
  font-size:16px;
}

.pfcs-account-plan-label{
  font-weight:700;
  color:var(--pfcs-text);
  font-size:16px;
}

.pfcs-account-plan-badge{
  display:inline-flex;
  align-items:center;
  padding:4px 18px;
  border-radius:999px;
  font-size:15px;
  font-weight:800;
  border:1px solid #d5d7dd;
  background:#f1f2f6;
  color:#333;
}

.pfcs-account-plan-badge--premium{
  background:#ffe5e5;
  border-color:#f44336;
  color:#c62828;
}

.pfcs-free-plan-box{
  max-width:720px;
  background:#fff;
  border:1px solid var(--pfcs-red);
  border-radius:10px;
  padding:20px 22px 22px;
  margin:0 auto 22px;
  box-shadow:0 4px 14px rgba(0,0,0,.03);
}

.pfcs-free-plan-header{ margin-bottom:18px; }

.pfcs-free-plan-title{
  font-size:22px;
  font-weight:800;
  color:var(--pfcs-blue);
  margin:0 0 10px;
}

.pfcs-free-plan-intro{
  margin:0 0 10px;
  font-size:15px;
  color:#444;
}

.pfcs-free-plan-benefits{
  margin:0 0 14px 0;
  padding-left:20px;
  font-size:15px;
  color:#333;
}
.pfcs-free-plan-benefits li{ margin-bottom:4px; }

.pfcs-free-plan-cta{
  margin:8px 0 8px;
  text-align:center;
}

.pfcs-free-plan-cta .pfcs-free-plan-cta-link{
  display:inline-block;
  padding:8px 28px;
  border-radius:999px;
  background:var(--pfcs-red);
  color:#fff;
  font-weight:900;
  font-size:18px;
  letter-spacing:.02em;
  text-decoration:none;
}
.pfcs-free-plan-cta .pfcs-free-plan-cta-link:hover{
  background:var(--pfcs-red-dark);
}

.pfcs-free-request-box{
  border-top:1px solid #edf0f3;
  padding-top:14px;
}

.pfcs-free-request-title{
  font-size:17px;
  font-weight:800;
  margin:0 0 8px;
}

.pfcs-free-request-intro{
  font-size:14px;
  color:#555;
  margin:0 0 14px;
}

.pfcs-free-form-grid{
  display:grid;
  grid-template-columns:repeat(2, minmax(0, 1fr));
  gap:12px 18px;
}

.pfcs-free-form-field label{
  display:block;
  font-size:14px;
  font-weight:600;
  margin-bottom:4px;
  color:#333;
}

.pfcs-required{ color:var(--pfcs-red); margin-left:2px; }

.pfcs-free-form-field input,
.pfcs-free-form-field select,
.pfcs-free-contact-form input,
.pfcs-free-contact-form textarea{
  width:100%;
  border-radius:8px;
  border:1px solid #d1d5db;
  padding:8px 11px;
  font-size:15px;
}

.pfcs-free-contact-form textarea{
  min-height:80px;
  resize:vertical;
}

.pfcs-free-form-field--full{ grid-column:1 / -1; }

.pfcs-free-form-actions{
  margin-top:16px;
  text-align:center;
}

.pfcs-free-form-note{
  margin-top:14px;
  font-size:13px;
  color:#777;
}

@media (max-width:768px){
  .pfcs-free-plan-box{
    padding:14px 12px 16px;
    margin:10px 0 16px;
  }
  .pfcs-free-form-grid{ grid-template-columns:1fr; }
  .pfcs-free-plan-title{ font-size:18px; }
}